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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Saving changes to a DropDownGrid to the underlying datatable

Thread ID:

Created:

Updated:

Platform:

Replies:

60405 May 4,2007 02:02 AM UTC May 4,2007 03:38 PM UTC WinForms 2
loading
Tags: GridControl
Dan Garvin
Asked On May 4, 2007 02:02 AM UTC

(Haneef, I've opened this separate post to clearly state this specific problem.)

In the CurrentCellShowingDropDown event of grid1, I drop down a DropDownGrid (grid2) and set the datasource to a datatable. I've set...

grid2.Binder.DirectSaveCellInfo = true;
grid2.Binder.OptimizeListChangedEvent = false;

...so the datatable gets updated when the user leaves the cell.

However, if the user makes changes to a cell without leaving the active cell and just clicks on the dropdown arrow again to close grid2, the changes do not get saved to the datatable.

I need to find what event I can subscribe to to do a dtGrid2.AcceptChanges() or grid2.EndUpdate, or something so that changes are saved.

Any help is greatly appreciated. Thanks.

Administrator [Syncfusion]
Replied On May 4, 2007 10:06 AM UTC

Something to try.

Subscribe to the CurrentCellCloseDropDown event and in the event handler, try calling grid2.CurrentCell.ConfirmChanges(). (If that does not trigger the save, also try calling grid2.Binder.EndEdit().)

Dan Garvin
Replied On May 4, 2007 03:38 PM UTC

All I can say is...You the man!
The ConfirmChanges() worked. Thanks loads.
-dan

>Something to try.

Subscribe to the CurrentCellCloseDropDown event and in the event handler, try calling grid2.CurrentCell.ConfirmChanges(). (If that does not trigger the save, also try calling grid2.Binder.EndEdit().)

CONFIRMATION

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.

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

;