I found an interesting issue that I think may be a bug. I have a web page that displays a simple edit form with a textbox, a Telerik Modal popup window and a dropdown. All three have a required field validator. The problem I found is that when you open the modal popup window and then close it (doesn't matter whether you select an item or not) and then hit the Save button (leaving one or both of the other required fields empty) thus firing the required field validator and causing a validation error (all client-side validation) and then click the Cancel button, you get the following error:
Line: 122
Error: 'parentNode' is null or not an object
It's referring to code in the Telerik.Web.UI.ModalExtender prototype in the "hide" function:
hide:function(){
this
._restoreTab();
this
._attachWindowHandlers(false);
var
_15=this._backgroundElement;
if
(_15){
_15.parentNode.removeChild(_15);
this
._backgroundElement=null;
}
}
The outerHTML of the object "_15" is as follows:
"<DIV style="Z-INDEX: 10000; POSITION: absolute; FILTER: progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=50); BACKGROUND-COLOR: #aaaaaa; WIDTH: 1653px; DISPLAY: none; HEIGHT: 915px; TOP: 0px; LEFT: 0px; opacity: .5; mozOpacity: .5" class=TelerikModalOverlay unselectable="on"></DIV>"
As a side note, if you open the modal popup window, and close it and then click Cancel (without firing the validation event) everything works fine. However, it also fails (same error) if you leave a field empty, click Save causing a validation error, then fill in the all of the fields and click Save again (validation passes), but you get the same error.
Oh, and using DestroyOnClose is not an option as they may need to open the popup a second time. This fixes the problem stated above but does not allow the use to open the popup after they close it.
Any ideas on the problem here? Is it a bug in Telerik or am I doing something wrong?
Thanks,
Bob