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

[Solved] OnRowEditEnded Event

5 Answers 158 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Michael
Top achievements
Rank 1
Michael asked on 14 Apr 2009, 05:20 PM

I have a gridview that I am doing data entry in. I have the ValidationMode set to Row.
I want to save the edited data back to the database when the user moves off the row.
I am using the OnRowEditEnded event.

When I look at my ObservableCollection<T> data row in the OnRowEditEnded event, the data has not changed yet. So I can't use the OnRowEditEnded event to save the changes to the database. If I go back and edit the same row I see that the previous data changes have been pushed to my datasource. At what point is the edited data pushed to the ObservableCollection<T> datasource?

How can I save my edited gridview data to the database?

Thanks

 

5 Answers, 1 is accepted

Sort by
0
Accepted
Nedyalko Nikolov
Telerik team
answered on 15 Apr 2009, 08:58 AM
Hello Michael,

There is such an issue with previous version which is already fixed.
I'm attaching a running sample application with new (SP1_Q1_2009) assemblies.

Do not hesitate to contact us if you have any further questions.

Best wishes,
Nedyalko Nikolov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Michael
Top achievements
Rank 1
answered on 15 Apr 2009, 02:06 PM

Thanks Nedyalko

 

That fixes me up.

0
Michael
Top achievements
Rank 1
answered on 15 Apr 2009, 05:40 PM

Nedyalko,

I am updating the database when the row is changed. ValidationMode is Row. But if the user has put the grid in edit mode and is tabbing through the cells and rows, how can I tell if the data in a cell has changed? I don't want to update the database if the data has not changed. I must be missing a CellDataChanged event or something.

Thanks

0
Nedyalko Nikolov
Telerik team
answered on 16 Apr 2009, 07:13 AM
Hi Michael,

It seems that you've hit a bug in GridView control. So I've updated your Telerik points.

As a workaround you can use RadGridView.CellEditEndedEvent which is raised only when value of the edited cell is changed.

Sorry for the inconvenience caused.

P.S. Let me know is this is a showstopper for you. I'll do my best to arrange a custom build when fix is ready.


All the best,
Nedyalko Nikolov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Michael
Top achievements
Rank 1
answered on 16 Apr 2009, 02:09 PM
This isn't a show stopper. I can wait until the next release.

Thanks for your help.
Tags
GridView
Asked by
Michael
Top achievements
Rank 1
Answers by
Nedyalko Nikolov
Telerik team
Michael
Top achievements
Rank 1
Share this question
or