473,394 Members | 2,071 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,394 software developers and data experts.

Please Help : Check for existing window

Hi,

I need to check for a particular window which I opened as a popup,
already exists, before I try to open the same again. I achieved that
with the following code. So this is fine.

var myWin = null;
function openPopup(aURL){
if (( myWin==null) || myWin.closed) {
myWin = open(aURL,"myWin");
}

/* Window is already opn, thus maps the url to the same window
and give focus */
else {
myWin.location = aURL;
myWin.focus();
}
}

Now my problem is I need to do a similar check for a page thats been
href to the top.location
top.location=aURL;

In this situation if this same code runs again, i need to check if this
window is already open, and if so not to open it. Can it be done in a
similar way like the above.

Thanks for your time
Shiran.

Apr 7 '06 #1
1 1710
........... I am still struggling to find a solution for this

Apr 18 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: RAD | last post by:
I am working with an evaluation copy of SQL Server 2000 for the first time; my DB experience lies with MS Access. I have a simple table in SQL Server (tblCompany) that has a field called...
3
by: Bernd Liebermann | last post by:
Hi, I'm trying to change the content of an existing window from a second window using window.open(). This works fine in Netscape 7, but IE 6.0 returns an error, saying there's an invalid...
5
by: TrvlOrm | last post by:
Can any one please help me...I am new to JavaScript and I have been struggling with this code for days now and can't figure it out. I would like to get the Buttons to correspond with the action...
1
by: jp | last post by:
bigger image opens in new window within an existing javascript. I am working within a existing javascript. see www.art4companies.nl and press kunstenaars than press any name to see what I mean....
4
by: Raffi | last post by:
I need to do the following: From the main page I click a link button and open a javascript popup window. So far so good. Now when i try to open a new popup window from a button link in the first...
7
by: x muzuo | last post by:
Hi guys, I have got a prob of javascript form validation which just doesnt work with my ASP code. Can any one help me out please. Here is the code: {////<<head> <title>IIBO Submit Page</title>...
1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
2
by: blue_i | last post by:
Please tell me that how can i add the Triangle code in WM_PAINT i tried but failed. please this problem #include <windows.h> int APIENTRY WinMain(HINSTANCE hInstance, ...
1
by: Constantine AI | last post by:
I am wanting to import CSV files into Access, which isn't a problem at the moment the code i have is as follows: Dim strSQL As String Dim CSVTable As String Dim FilePath As String ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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,...
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
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...

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.