[MetadataType(typeof(PersonMetaData))]
public partial class Person {
public class PersonMetaData {
[Required(ErrorMessage="The number is required")]
public object Number {get;set;}
}
}
This error message is displayed when the number field is empty and when there is an invalid input that it gives "The value" foo "is not valid for the number.". How to configure the last error message?
source
share