Wednesday, May 30, 2012

Ajax Update Panel and Required Field Validators

Ran in to an issue this morning, where the cancel button's causesvalidation="false" property was not functioning correctly.

Basically the whole page froze up if the validation failed. This(validator) was inside a formView inside an Update Panel on a Sharepoint WebPart. Researched and found this, which gave me pointers to try.

http://www.codeproject.com/KB/ajax/UpdatePanel_Validation.aspx

Finally, adding EnableClientScript="false" to the Required Field validator made the cancel button work properly.​

No comments: