Quantcast
Channel: AjaxControlToolkit Work Item Rss Feed
Viewing all articles
Browse latest Browse all 4356

Commented Issue: ModalPopupExtender and ValidationSummary not working on Page_Load [27024]

$
0
0
I have a ModalPopupExtender (mpeAddEdit) that shows on page load. In the ModalPopupExtender there is a ValidationSummary Control (vsDutyLog). If the validationsummary control is present or enabled, then when the call to how the ModalPopupExtender in Page_Load (mpeAddEdit.show() ) , generates an error in the javascript: 'Microsoft JScript runtime error: Object expected' at the line(s) in the javascript reading:

document.getElementById('cphBody_vsDutyLog').dispose = function() {
Array.remove(Page_ValidationSummaries, document.getElementById('cphBody_vsDutyLog'));
}
(function() {var fn = function() {Sys.Extended.UI.ModalPopupBehavior.invokeViaServer('cphBody_mpeAddEdit', true); Sys.Application.remove_load(fn);};Sys.Application.add_load(fn);})();

If the ValidationSummary control is not enabled, or is commented out, then there are no errors generated. Also, if the ModalPopupExtender is shown at any other time than page load, there are no errors (i.e. shown via clicking a link).

It seems like this was somewhat of an issue once before and that the issue related to incorrectly generated javascript (see http://forums.asp.net/t/1175339.aspx/1). The work around here defined seems to alleviate the issue, but then the ValidationSummary is not usable as it is diabled. (See also http://ajaxcontroltoolkit.codeplex.com/workitem/12835?ProjectName=ajaxcontroltoolkit for more information about a suitable interim workaround).

For me this is a high priority issue as it directly affects work I'm currently doing.
Comments: This is still an issue, I just tried the code fix listed in one of the comments above, but it only bypassed validation. At this point I am unable to use the asp:RequiredFieldValidator on a ajasxControltoolkit modal popup. =(. Please notify when a solution or patch is provided.

Viewing all articles
Browse latest Browse all 4356

Trending Articles