473,657 Members | 2,528 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how do i pop a window once i close the current one using the X button?

16 New Member
what is the condition if i want to pop a new window once i close the current one? is it..?
Expand|Select|Wrap|Line Numbers
  1. if window.close
  2. {
  3. window.open("abc.aspx", "abc", 'toolbar=0,scrollbars=1,location=0,statusbar=yes,menubar=no,resizable=no,width=800,height=220,left=100,top = 145');
  4. }
  5.  
i've tried it. but it didnt work.
Jul 16 '07 #1
6 1532
gits
5,390 Recognized Expert Moderator Expert
... you may use the 'onbeforeunload '-handler of the current document-body ... but i hope you don't want to create such an annoying popup-cascade ... ;))

kind regards
Jul 16 '07 #2
tabakaka
16 New Member
what is the condition if i want to pop a new window once i close the current one using the X button on the title bar (minimize, restore, CLOSE)? is it..?

Code: ( text )
if window.close
{
window.open("ab c.aspx", "abc", 'toolbar=0,scro llbars=1,locati on=0,statusbar= yes,m enubar=no,resiz able=no,width=8 00,height=220,l eft=1 00,top = 145');
}


i've tried it. but it didnt work.
Jul 16 '07 #3
gits
5,390 Recognized Expert Moderator Expert
what is the condition if i want to pop a new window once i close the current one using the X button on the title bar (minimize, restore, CLOSE)? is it..?

Code: ( text )
if window.close
{
window.open("ab c.aspx", "abc", 'toolbar=0,scro llbars=1,locati on=0,statusbar= yes,m enubar=no,resiz able=no,width=8 00,height=220,l eft=1 00,top = 145');
}


i've tried it. but it didnt work.
have a look here ... you double posted it ...

your other tread

kind regards
Jul 16 '07 #4
tabakaka
16 New Member
have a look here ... you double posted it ...

your other tread

kind regards
i was asking for the X button on the title bar. i didnt think your answer answered my question. thanks again
Jul 16 '07 #5
gits
5,390 Recognized Expert Moderator Expert
the 'X'-button closes the window ... so isn't it the same? ... explain the difference ... and when there is no difference ... then an answer to one question is the answer to
the other question too ...

the mentioned event within your other thread is to be implemented in the document-body ... and it will do the job when the window is getting closed ... whatever way this might be done ... you cannot ask for a specific button to do that ... in case that this! is your question ...

kind regards ...
Jul 16 '07 #6
acoder
16,027 Recognized Expert Moderator MVP
have a look here ... you double posted it ...

your other tread

kind regards
No longer another thread. I've merged the two threads.
Jul 17 '07 #7

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

Similar topics

10
14709
by: Scott | last post by:
I'm new to ASP, but I've been programming in VB for several years, and I'm having a few issues with this ASP enhancement I'm working on. I've found ASP to be a lot different than what I'm use to in VB. I've created an ASP interface where a user can select an email group that populates a listbox with those email addresses. If a user sees an email in that list that they do not want then they can remove it by clinking the Delete button...
6
8525
by: chon | last post by:
I have an ASP page that is sent a file location as a parameter. It opens this file, loads the ADODB.Stream object and does a binary write to the page forcing the download dialog to appear. This all works fine. If the user selects "Open" or "Cancel", the window closes, which is the desired behavior. If they select "Save", the location dialog shows up, they save the file and the window remains open. I've tried a number of things to get...
1
1266
by: Lisa | last post by:
I have a Perl script that's called as a CGI to handle the form submission from a browser, thru which a user from the web can up load an image file. I would like, when the user clicks the "Send Image" button, to pop up a small window containing an animated (working - please be patient) .gif while the image is uploaded from thier computer to the server, once the transfer is complete, I would like to close the pop up window and then load the...
1
11566
by: Earl Teigrob | last post by:
I did a ton of searching to try and find a simple solution to this issue and finally wrote my own, which I am sharing with everyone. In my searching, I did find a very complete and robust solution at http://weblogs.asp.net/asmith/archive/2003/09/15/27684.aspx but it was far more complex then I needed. (I got lost trying to figure it all out). Therefore, here goes my simple "web dialog box with parent event handler fireing" solution. ...
7
5814
by: Toccoa | last post by:
After considerable googling - I mean searching with Google(r) - I could not find javascript on a button or <a href=... to close a window in the latest versions of IE and FireFox. There seemed to be two techniques for earlier versions. But the window.opener='' ;window.close(); and the window.open('','_parent','') ;window.close(); techniques do not work for me. I.e., I still get confirmation message
1
1771
by: Garg | last post by:
Hi, I am facing a problem while trying to close a window that I've opened in a frame. I am using javascript to close my current popup window. I have written the following line of code on click of OK button event. Response.Write("<scriptwindow.close();</script>") Now the problem is since this window is closed, the frame is still
2
3260
by: wreed06 | last post by:
Hello, I have 2 problems. In my webpage, I have a dropdown list with a button that takes the user to a popup window specific to the option. I am using Firefox 2.0.0.13. I have successfully validated my HTML and CSS code. 1. When I clear cache and refresh my webpage, it takes 3 tries before the popup window displays - I click on the button once, a white window the size of my webpage displays. I close it and click on the button again (for...
0
8425
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8845
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8743
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
7355
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6177
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5647
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4333
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2745
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1973
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.