C# ASP.NET MVC Forms Adding Form Validation Displaying Validation Messages

kevin hudson
PRO
kevin hudson
Pro Student 9,652 Points

I can't see where the Action field error message is defined within the solution

"The activity field is required." Is displayed when and activity isn't selected but where does this message come from?

1 Answer

Steven Parker
Steven Parker
202,065 Points

That's the default message provided for required fields. And any non-nullable field is automatically handled by the data binder as required, just as if it had a "[Required]" data annotation.