Suppressing 'Do you want to save changes?' after a inserting a new row.

DerekC

Member
Joined
May 5, 2009
Messages
20
Programming Experience
5-10
hi, I check for any changes for a new row on a bindingsource, and prompt the user to save changes if they close out of the form or click a new row on the master datagridview. However, I don't want to prompt if a new row has been inserted and nothing else has changed. At the moment, I insert a row and set some default values, but then it asks me to save. Is there a way to ignore certain fields? ie the default values? Any help would be great.
 
You loop table.GetChanges(DataRowState.Added).Rows and check each column value against the columns DefaultValue.
 
Back
Top