Asp net validating drop down lists
I am new to MVC and I am still trying to explore stuffs inside MVC.
Now I came to place where I need to implement validation for drop-down list.
If you don't include these js files, the validation will not work.
Please check that you have included the jquery.validation library files in your layout page.
If you have any compliments or complaints to MSDN Support, feel free to contact [email protected]
I created model class like this : Here what I want is when my drop-down list is in Select Mode that is default, it should show please select at least one option error and if user selects 1st or 2nd option then this error message should not display.
Model: You could also store other properties on the option model if needed.