It is a security measure to prevent a script from closing a browser window. The only thing that is supposesed to be closable are windows that were opened using javascript.
However, there is an IE only workaround (note I got this info from other people and sources):
Put this code in the browser page:
<OBJECT id=closes type="application/x-oleobject" classid="clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11">
<PARAM NAME="Command" VALUE="Close">
</OBJECT>
<script language="JavaScript1.2">
<!--
function closeWin() {
if (typeof window.ActiveXObject != 'undefined') {
try {
closes.Click();
}
catch (error) {
alert(error);
}
}
else {
//this means the browser does not support the ActiveX object and you cannot close the browser window
//put whatever you want here
}
}
//-->
</script>
And put this code in the pop-up window (the way I understand it, you want the pop-up to close everything).
if(window.opener && !window.opener.closed) { opener.closewin(); }
//now put your code to close the pop-up