Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
AI OnAI Off
Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
You can use @Html.ValidationMessageFor, e.g @Html.ValidationMessageFor(m => m.Ssn, Html.Translate("/formerror/ssnrequired"))
The suggestion from Tim works, but the error messages are always rendered with <span class="field-validation-valid"></span> or <span class="field-validation-error"></span>. This was confusing for me at least. :)
Hi
I am trying to show localized error messages. I dont want hardcoded messages in my model. I have removed code to keep it simple.
My model
My view
I guess i have to use ErrorMessageResourceType and ErrorMessageResourceName but how do i do that?
Cheers Øyvind