Help shape the future of CMS PaaS release notes! Take this quick survey and share your feedback.
AI OnAI Off
Help shape the future of CMS PaaS release notes! Take this quick survey and share your feedback.
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