473,414 Members | 1,621 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

Closing Pop UP window automatically when Parent window is closed

nitindel
Hi
Guys...


I am looking for a functionality of closing the POP UP window that i have opened from a Parent window....Whenver i Close the Parent window..


I mean to say...
Whenver i close the parent window ..the pop up shold also be closed automaticallly...

Thanks
Feb 22 '08 #1
4 5213
acoder
16,027 Expert Mod 8TB
You can close the popup onunload with popup.close().
Feb 22 '08 #2
Hi
Guys...


I am looking for a functionality of closing the POP UP window that i have opened from a Parent window....Whenver i Close the Parent window..


I mean to say...
Whenver i close the parent window ..the pop up shold also be closed automaticallly...

Thanks
here is the code check it out..!!!
Expand|Select|Wrap|Line Numbers
  1.  var newwin=window.open();
  2.                 newwin.resizeTo(screen.width,screen.height);
  3.                 newwin.moveTo(0,0);
  4.                   newwin.close();
  5.  
  6.  
Feb 22 '08 #3
here is the code check it out..!!!
Expand|Select|Wrap|Line Numbers
  1.  var newwin=window.open();
  2.                 newwin.resizeTo(screen.width,screen.height);
  3.                 newwin.moveTo(0,0);
  4.                   newwin.close();
  5.  
  6.  
do this(newwin.close();)after the parent window.close() is executed
Feb 22 '08 #4
acoder
16,027 Expert Mod 8TB
do this(newwin.close();)after the parent window.close() is executed
If it's after, the window will already be closed.

Anyway, that still doesn't allow for closing the browser manually.
Feb 22 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

10
by: Tom Szabo | last post by:
Is there an event when that triggers when the window is closing.... I am talking about when the user clicks on the cross on the right top corner of the window!!!
5
by: Ron L | last post by:
I have an MDI application with a number of child windows. In each child window I am catching the Closing event and having the child window decide if it should set cancel to true. The intent here...
1
by: Chris Bruce | last post by:
In my application I need a way to distiguish between the following events: 1. When a user closes an MDI child window. 2. When the user closes the MDI parent window which subsequently closes the...
6
by: Gary Miller | last post by:
Does anyone know how to detect a modeless form on closing by the form that invoked the modeless form? form.Show();
6
by: sramruttun | last post by:
hi I open a pop up window using window.showModalDialog. How can I close the parent window after the pop up appears ?
10
by: Charles Law | last post by:
For some reason, when I click the X to close my MDI parent form, the action appears to be re-directed to one of the MDI child forms, and the parent remains open. I am then unable to close the...
10
by: Tony | last post by:
I need to know how to open a pop up and close the main window without a prompt in Firefox 2 and IE 7. Anybody have any ideas on how to do that. I currently have this and it works in IE 6 and...
4
by: reemamg | last post by:
From a parent window a new child window is open with window.open <script type="text/javascript" language="JavaScript" > function abc() { if(window.event.clientY <0 &&...
7
by: sumanta123 | last post by:
Dear All, How will we do in JSP page on closing the parent window the child windows should close automatically. I will show my code Please i will show you my code. For HTML link function...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.