We want to identify Whether a record/records in the grid have been changed by the user or not.
For e.g. We Query a set of records from the db and show it in a grid. When we have to save the changes in the form,we want to find out which records in the grid have been Changed by the user and call the db operations only for those records.
What is the best way to do this ?
ADAdministrator Syncfusion Team January 13, 2005 07:34 AM
The grid does not really track what records have changed, but if you are using a DataTable datasource, it does.
You can use a DataView to get the modified records, or you can loop through the DataRows in teh DataTable and check each row''s RowState to see if it has been modified.
//dt is the datatable
DataView dv = new DataView(dt, "", "", DataViewRowState.ModifiedCurrent);
for(int i = 0; i < dv.Count; ++i)