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

[Solved] Required validator 'not working'

0 Answers 34 Views
Editor
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Steven
Top achievements
Rank 1
Steven asked on 18 Nov 2010, 03:19 PM

The required data annotation does not always seem to work on viewmodel properties that are edited through the Telerik MVC Editor.

Let's take the client validation demo on the Telerik site as an example:

  1. Go to: http://demos.telerik.com/aspnet-mvc-beta/editor/clientvalidation
  2. Don't touch the editor, just press save
  3. Validation works in this case

But now ... :

  1. Again, go to: http://demos.telerik.com/aspnet-mvc-beta/editor/clientvalidation
  2. Enter some random text in the editor.
  3. Clear the text you entered in step 2.
  4. The editor seems to be empty now (to the user), but in the background there's still an empty paragraph in it (<p></p>).
  5. Press save.
  6. Validation failes.

Is there anything I can do to fix this issue? Thanks in advance.

Regards

Tags
Editor
Asked by
Steven
Top achievements
Rank 1
Share this question
or