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

[Solved] How to tell the grid that the operation failed?

1 Answer 71 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Marc Simkin
Top achievements
Rank 2
Iron
Iron
Veteran
Marc Simkin asked on 10 Jul 2011, 03:57 PM
Hi:

I am using the grid with Ajax binding and pop up editing.  During the grid action call, I'm doing additional validation on the data returned.

If the data fails validation, I'm adding a model error to the model state.

When I rebind the grid via the return View(new GridModel()) call, will it see the model state error and return the error to the client.  The the pop be redisplayed with the contents of all the fields as they were for the call?  Will the error be highlighted.

If not, how can I make the pop re-appear with the values used duing the call?

Thanks

marc

1 Answer, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 11 Jul 2011, 08:14 AM
Hello Marc Simkin,

Indeed, additional model state errors will be shown during editing, however they should be associated with a field already visible in the edit form. I have attached a small sample which demonstrates this.

Regards,
Rosen
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Tags
Grid
Asked by
Marc Simkin
Top achievements
Rank 2
Iron
Iron
Veteran
Answers by
Rosen
Telerik team
Share this question
or