hi guys! i need your help. how will i able to know if the datagridview values has changes? i want to trigger it in button close, and i want to ask the user if he or she wants to save the changes.. thanks!
Printable View
hi guys! i need your help. how will i able to know if the datagridview values has changes? i want to trigger it in button close, and i want to ask the user if he or she wants to save the changes.. thanks!
The grid itself has no idea whether its data has changed or not. If you're bound to a DataTable you can call its GetChanges method and if it does not return null then some data has changed. If you're unbound or bound to some other list that doesn't tell you itself then you'll need to remember yourself by setting a flag when the grid raises a CellValueChanged event.
thanks!! you're so great!!!