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. Image for the cookie policy date

GGC event when cell change causes DataSet to change

Hi, I''m looking for the correct event to use for the situation when a change to a GGC cell makes the underlying dataset''s "HasChanges" method return true. All I''m really trying to do is enable/disable the toolbar "save" button as soon as changes are made to a grid cell ... at first I thought the dataset would have an event like that, but it doesn''t seem to. I''ve tried TableControl_CurrentCellAcceptedChanges event, but although it fires at the right time, the HasChanges() method doesn''t return true until more than 1 cell has been changed. Hopefully what I''ve said is understandable ... Thanks. Ross.

3 Replies

AD Administrator Syncfusion Team October 6, 2005 10:04 PM UTC

Try handling the CurrentRecordContextChange event. In your handler, check for e.Action == CurrentRecordAction.CurrentFieldChanged.


RP Ross Prestmo October 7, 2005 02:49 PM UTC

Thanks for the response. The event fires at the time that I want it to, but the cell change doesn''t seem to get written to the Dataset right away (ie. the HasChanges() still returns false at that point). It seems that I have to either make a change in another cell or move to a different record before the dataset''s HasChanges() method will return true. Is there some way to force the cell change to be written to the dataset right away? Thanks for your help. Ross.


AD Administrator Syncfusion Team October 7, 2005 03:33 PM UTC

You can try calling EndCurrentEdit on the CurrencyManager to see if that does what you need. if(e.Action == CurrentRecordAction.CurrentFieldChanged) { this.gridGroupingControl1.CurrencyManager.EndCurrentEdit(); }

Loader.
Live Chat Icon For mobile
Up arrow icon