Our ASP.Net and legacy code share a little blob of open-source javascript that implements a calendar control in a popup window. The window.open() call that creates the popup window uses about:blank as the root url.
There are navigation arrows around the month and year to change the presentation of the days of the month, and the year has an input field that's supposed to be directly editable. Whenever you click on the arrows or edit the year, it's supposed to re-draw
the days-of-the-week layout to match the new year/month. All the code to do the navigation lives in the original parent page's context, not the popup window's.
The weird bug is that if you type anything in the editable year field, it throws a "Call was rejected by callee" in IE at the line
if (this.popupWindow != null && !this.popupWindow.closed)
on the latter clause.
The odd thing is that this refresh routine containing the above line is called when you open the popup, when you use the navigation arrows (implemented with javascript hrefs on anchors), and when in the onkeypress event of the year input
- and only the onkeypress invocation is throwing the callee exception.
From what I can find searching around, it seems generally like the error message indicates that IE thinks this is some kind of cross-domain window exception, but I can't find a lot of details and nothing to explain why the same function call would work in
an href action and not in an onkeypress action.
mmodrall
Member
24 Points
50 Posts
"Call was rejected by callee" in popup window, tied to onkeypress event
Nov 27, 2012 07:10 PM|LINK
Hi...
Our ASP.Net and legacy code share a little blob of open-source javascript that implements a calendar control in a popup window. The window.open() call that creates the popup window uses about:blank as the root url.
There are navigation arrows around the month and year to change the presentation of the days of the month, and the year has an input field that's supposed to be directly editable. Whenever you click on the arrows or edit the year, it's supposed to re-draw the days-of-the-week layout to match the new year/month. All the code to do the navigation lives in the original parent page's context, not the popup window's.
The weird bug is that if you type anything in the editable year field, it throws a "Call was rejected by callee" in IE at the line
if (this.popupWindow != null && !this.popupWindow.closed)
on the latter clause.
The odd thing is that this refresh routine containing the above line is called when you open the popup, when you use the navigation arrows (implemented with javascript hrefs on anchors), and when in the onkeypress event of the year input - and only the onkeypress invocation is throwing the callee exception.
From what I can find searching around, it seems generally like the error message indicates that IE thinks this is some kind of cross-domain window exception, but I can't find a lot of details and nothing to explain why the same function call would work in an href action and not in an onkeypress action.
Anyone have any ideas?
Thanks
Mark