Enable client side validation is not working
Actually i am using server side validation and saw article that only adding link to java script file and using <%Html.ClientValidationEnabled = true%> will automatically enable client side validation but first of all i am using Visual Web Developer 2010 Express 4.0.30319 and here it show error that <%Html.ClientValidationEnabled = true%> does not exist i dont know
what reference i need for enabling this. Second i try to use <% Html.EnableClientValidation(); %> it is not givin开发者_开发百科g any error but also not working my page is posting back and only server side validations are working.Try following Scott Gu's excellent blog post about Model Validation and you should get it working.
Isn't it
...Form fields go in hereand you need script references for MicrosoftAjax.js and MicrosoftMvcValidation.js
精彩评论