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

[Solved] Showing Error Message from a Custom ValidatorProvider

0 Answers 29 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.
Kuangyi
Top achievements
Rank 1
Kuangyi asked on 20 Sep 2011, 04:28 PM
Hi, I have a custom validation provider registered in my code for an object I'm binding to a grid.

eg:
in GlobalAsax I have ModelValidatorProviders.Providers.Add(new Obj1ValidationProvider()); and Obj1ValidationProvider inherits from ModelValidatorProvider.

in my grid I have

Html.Telerik().Grid(Model.Obj1Instance)
... etc ...

The error messages set by my Obj1PropertyValidator aren't shown by the grid.  How do I get them to show?  Normally I'd just use Html.ValidationMessageFor(...) however I can't wrap a grid in a BeginForm() without my edit/delete buttons failing.

Thanks
Tags
Grid
Asked by
Kuangyi
Top achievements
Rank 1
Share this question
or