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

What event happens before the datasource updates?

1 Answer 11 Views
Grid
This is a migrated thread and some comments may be shown as answers.
adam
Top achievements
Rank 1
adam asked on 05 Dec 2014, 05:30 PM
I am attempting to validate some data in a cell before the datasource of the grid gets modified.

Which event would allow me to inspect this cell after the user has left the cell, but before the datasource is modified?

1 Answer, 1 is accepted

Sort by
0
Viktor Tachev
Telerik team
answered on 10 Dec 2014, 09:45 AM
Hello Adam,

Depending on the EditMode that you have set for RadGrid you could use different approaches.

In case you have Batch Editing enabled you should validate the input client-side. To validate the value in a cell you can use the OnBatchEditClosing client event of RadGrid. In case the value is invalid you can prevent the edited cell from closing and prompt the user. If you would like additional information on Batch Editing you would fine the following article interesting:


If you are using another editing mode you can perform server-side validation. You can use the OnUpdateCommand handler to validate the user input. Check out the article below that describes how you can validate the data in RadGrid.



Regards,
Viktor Tachev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Grid
Asked by
adam
Top achievements
Rank 1
Answers by
Viktor Tachev
Telerik team
Share this question
or