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
close icon

GDBG RowState behaviour with "enter" key

We are using GridDataBoundGrid (latest Syncfusion version). We use a DataTable as the DataSource. The DataTable is typically a query result from a database. We need to know when the user modifies a cell. I can iterate through the rows in the DataTable and check RowState, which works fine - except when the user hits the "return" (enter) key to complete the cell edit: If they edit some text in a cell and then mouse click on another row, RowState is "modified" as expected. If they edit text and hit return, the currentcell advances to the next column and the RowState is "unchanged" - not good. It seems that if the user hits return to complete and edit, the grid is calling AcceptChanges. Is there any way to disable this? thanks! john

1 Reply

AD Administrator Syncfusion Team April 19, 2006 01:27 PM UTC

Hi John, By Default,The databound grid will push all data for a row into the underlying datasource for every record once you move the current cell of that record. Once the changes for a record have been pushed into the datasource the grid has no more knowledge about these changes and thus cannot reverse and undo these changes.It does not push all data for a row into the underlying datasource for every cell movement.If you want to push all data to undelying datasource for every cell movement,you need to call in Binder.EndEdit Method(before calling this , you need to call the CurrentCell''s Edit method),Here is a code snippet. this.gridDataBoundGrid1.CurrentCell.EndEdit(); this.gridDataBoundGrid1.Binder.EndEdit(); For more details,See http://www.syncfusion.com/Support/user/uploads/DataBoundGrid_239d47b2.zip Please let me know if you need any further assistance. Regards, Haneef

Loader.
Live Chat Icon For mobile
Up arrow icon