Hello Telerik:
Do you have any sample where the new rows inserted by the user have a 'exists' rule validation to prevent duplicate items in a batch editing grid?
Thank you.
Oscar.
1 Answer, 1 is accepted
0
Georgi Tunev
Telerik team
answered on 31 Jan 2012, 04:54 PM
Hi Oscar,
We don't have such example, but this is a general case, that is not directly related to the Grid component and should be handled by custom user code. Basically, what you need to do is to implement a custom check in the save action (_SaveBatchEditing in the demo) and in case of a problem like a duplicate item, to raise ModelState error. The function hooked to the Grid's OnError event will display that error to the user.
All the best,
Georgi Tunev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now