This question is locked. New answers and comments are not allowed.
When a row is being edited, the new values entered into the cells are being directly bound to my item. What is the best way to handle the Cancel action to restore the item to what it once was?
The GridViewRowEditEndedEventArgs contains the old values, so I could in theory set them back into the item. My item also has Backup/Restore functionality intended to support this style of editing. In either case, though, the EventArgs' EditedItem is null (for an existing item being edited). I'm considerign getting the Item property of the EventArgs' Row, but this is starting to feel more and more wrong.
What is the best way to restore an item to its original state when cancelling a row edit?
The GridViewRowEditEndedEventArgs contains the old values, so I could in theory set them back into the item. My item also has Backup/Restore functionality intended to support this style of editing. In either case, though, the EventArgs' EditedItem is null (for an existing item being edited). I'm considerign getting the Item property of the EventArgs' Row, but this is starting to feel more and more wrong.
What is the best way to restore an item to its original state when cancelling a row edit?