Pages

Saturday, October 24, 2009

Validation Summary and AjaxControlToolkit's ModalPopupExtender

Hi Guys,
Recently I come across a situation where in I used a AjaxControlToolkit's ModalPopupExtender with in a aspx page and it was working fine. Until when I added a simple form with validation controls. Obviously, I had a validation summary control too.

The application threw a JavaScript error "Object Expected" and in a mean time I came to knew that there is a issue with "Validation Summary" control and AjaxControlToolkit's "ModalPopupExtender" control.

Check this link from asp.net forums for details.

In order to get this done we need to disable the validation summary control before opening the modal pop up. In some posts, I find a way of using "ValidationGroup" property of asp.net controls (but this don't solve my issue).

The only solution I got is from by favorite scripting language "JavaScript" by writing custom validation to it. Problem solved... :-)

If you have any other solution for this issue, please feel free to comment.

Hope this helps,
Sreekanth