Solved

close a popup when parent form closes

Posted on 2004-09-16
2
295 Views
Last Modified: 2010-04-17
how do i close a popup when the parent form is closed. the parent form is a .ascx file and the popup is html.
0
Comment
Question by:coletteck8
2 Comments
 
LVL 4

Accepted Solution

by:
Sicos earned 125 total points
ID: 12078848

Just store a reference to the window.

Declare a global javascript variable ...

var goWindow;

When you open the window open it like this ... goWindow = window.open(....);

When youre main window is closed use the unload event to close the other window like

goWindow.close();

Greetings,
Sicos
0
 

Author Comment

by:coletteck8
ID: 12078906
what code do i use to check if the main window is closed? can i use the onUnload method?
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
fix34  challenge 9 98
scoresClump  challenge 31 108
move one pixel 4 41
Please explain: Aspect Oriented Programming 2 57
Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now