We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

ggc.Table.CancelEdit() - not good enough

Thread ID:





60620 May 9,2007 12:04 PM UTC May 9,2007 11:34 PM UTC WinForms 4
Tags: GridControl
Ryan Hardoon
Asked On May 9, 2007 12:04 PM UTC

Hi everybody,

I have a scenario that requires me to use CancelEdit() from within TableControlCurrentCellAcceptedChanges (when data validation fails).

Using CancelEdit() alone causes "AddNew not called" exception when I re-edit the cell without losing focus.

I tried to send Esc key, but then there are situations in which the cell's buffer (the new-rec buffer actually) is not cleared, and re-entering a field causes the other, previously edited fields, to display the bad data without the TableControlCurrentCellAcceptedChanges validation.

1) (the preferred solution) How do I override the "AddNew" problem ?
2) (an undesired alternative) If the above is impossible, how do I clear the edited cell's buffer after calling CancelEdit() ?

Thnaks in advance.

Ryan Hardoon
Replied On May 9, 2007 12:15 PM UTC

Assuming TableControlCurrentCellAcceptedChanges validation is good, how do I force "AddNew" from within TableControlCurrentCellAcceptedChanges - if and only if the currently edited record does not already represent a valid data (DataRow) in the ggc's DataSource (DataSet) ?

Ryan Hardoon
Replied On May 9, 2007 02:36 PM UTC

I just noticed that SendKeys() actually made no difference.
The cell's buffer is not cleared either way.

Please assist ASAP.

Best regards.

Ryan Hardoon
Replied On May 9, 2007 10:38 PM UTC

Somebody . . .

Anybody . . .

? ? ?

haneefm [Syncfusion]
Replied On May 9, 2007 11:34 PM UTC

Hi Ryan,

If you want to actually add new items to the arraylist(IList) through the GridGroupingControl, then you should also have your arraylist implement IBindingList to support the addnew functionality directly from the grid. Please refer this sample:

C:\Program Files\Syncfusion\Essential Studio\\windows\Grid.Grouping.Windows\Samples\CustomCollections\StronglyTypedCollection\

Best regards,


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon