For one of my project requirement, i need to perform validation over some control. (MVC 5 , Data annotation, JQuery)
Looking some different approach, i need data annotation validation handled through JQuery
I have following control on my page with validation using data annotation on all these control: 1) Username 2) EmailId 3) Contact No 4) Password 5) Confirm Password
Initially top 1-3 controls are blocked and and 4-5 control is set to display none So, i need validation should not check for 4-5 when i press submit button.
Later it will show 4-5 control and 1-3 control is set to display none. in that case i need validation should not check for 1-3.
NOTE: There is only one View page, can't have multiple view pages
How can i enable and disable data annotation validation using JQuery.