Export (0) Print
Expand All
1 out of 12 rated this helpful - Rate this topic

ModelStateDictionary.AddModelError Method (String, String)

Adds the specified error message to the errors collection for the model-state dictionary that is associated with the specified key.

Namespace:  System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)
member AddModelError : 
        key:string * 
        errorMessage:string -> unit

Parameters

key
Type: System.String

The key.

errorMessage
Type: System.String

The error message.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.