This is a migrated thread and some comments may be shown as answers.

Cell edits not persisting

1 Answer 67 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Pete
Top achievements
Rank 1
Pete asked on 31 Aug 2011, 12:43 AM
This is by far the strangest bug I've encountered.

If I select a cell for edit using the mouse and edit the cell and then select another cell using the mouse, and edit the newly selected cell, when I save the values revert.  If I perform the same edits but rather than selecting cells using the mouse I instead tab to the cell, or hit enter to move to the next row, and edit a different cell my edits persist.

On the off chance someone has encountered this or a similar kind of behavior I'm posting this in the hopes of getting this resolved.

I'm using entity framework 4 as my O.R. and like I said when I navigate using the tab key there are no problems. It's only when I make cell selections via the mouse. 

Frankly I'm stumped so any suggestions as to what might be causing this will be greatly appreciated.

Thanks in advance.


1 Answer, 1 is accepted

Sort by
0
Pete
Top achievements
Rank 1
answered on 31 Aug 2011, 01:10 AM
RESOLVED.

Interesting this is.

When using the keyboard to navigate the RadGridView the event CurrentCellChanged is raised before SelectionChanged.  When selecting via the mouse  SelectionChanged is raised before CurrentCellChanged.  In my code I was only committing my edits in CurrentCellChanged event handler.  Also committing any edits in the SelectionChanged event handler resolved my issue. 

Tags
GridView
Asked by
Pete
Top achievements
Rank 1
Answers by
Pete
Top achievements
Rank 1
Share this question
or