Closing popup window

Results 1 to 2 of 2

Thread: Closing popup window

  1. #1
    Join Date
    Dec 1969

    Default Closing popup window

    I am trying to code closing a popup window before opening another one from the parent window, because I have to open the popup with different parameters from the same parent . (One option with toolbar in IE, another without, etc.) I use the following Javascript code:<BR><BR>if (windowHandle1 != null) {<BR> if (!windowHandle1.closed){<BR> windowHandle1.close();<BR> }<BR>}<BR><BR>windowHandle1 =, "WIN1", "status = YES, toolbar = NO, menubar = NO, location = NO, resizable = YES, scrollbars = YES");<BR><BR>This works fine. However, if there is a Response.redirect in the popup window, then the close popup window from parent does not work. Any ideas to work around this?<BR><BR>THanks

  2. #2
    Join Date
    Dec 1969
    Los Angeles, CA

    Default You cant do anything

    it is a security issue<BR><BR><BR>the only way it will close without the confirmation message is if it was opened with, the second you do a redirect or a location.replace or whatever you cant close it<BR><BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts