473,500 Members | 1,668 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Objects and popup-windows

Hi,

I'm developing a Javascript intranet app that consists of a number of
windows. I have a variable called TopWin that points to the original,
first window (found using the opener method). Some javascript files
that are used everywhere are included only by that window and the
methods are called using TopWin e.g. TopWin.DoQuery(). Everything seems
fine in Firefox.

In IE6 I have a problem. If I want to instantiate an object from Topwin
inside a popup, it won't let me e.g.:
var fred = new TopWin.TableScan();
works from frames of TopWin but in other windows IE says:
"Invalid procedure call or argument"

Do I have to include the Javascript files in every window or is there a
more elegant solution? (I see the question has been asked here before;
April 23 2000 but no-one replied).

Thanks in advance for any help

Jon

Jul 23 '05 #1
2 1414
Ivo
"JonQuark" wrote

In IE6 I have a problem. If I want to instantiate an object from Topwin
inside a popup, it won't let me e.g.:
var fred = new TopWin.TableScan();
works from frames of TopWin but in other windows IE says:
"Invalid procedure call or argument"

Do I have to include the Javascript files in every window or is there a
more elegant solution?


Did you try:
TableScan=TopWin.TableScan;
var fred = new TableScan();

And what is wrong with including your script files in all pages? After they
've been downloaded, they are available straight from the cache.
hth
--
Ivo

Jul 23 '05 #2
<Unable to instantiate new objects from another window in IE>
Do I have to include the Javascript files in every window or is there a more elegant solution?
<Ivo wrote:>Did you try:
TableScan=TopWin.TableScan;
var fred = new TableScan();


Yes I did, it creates the object without error but I get an error when
I access the member variables. I have admitted defeat (at least for
now) and included the javascript in every window. This is inelegant as
I'm using TopWin method for transferring data between windows, when I'm
using objects they javascript is included locally which is inconsistent
and prevents using objects for certain things.

Ah well, hopefully one day IE7 will make this more consistent or other
browsers will make IE obselete....

Jon.

Jul 23 '05 #3

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

Similar topics

6
2979
by: Mica Cooper | last post by:
Hi, I have a series of Select menus on a page. I am trying to allow the user to click on the Select title and have it popup a help window. This works fine with the following code except that all...
10
3047
by: soup_or_power | last post by:
The pop up window has several checkboxes. I'm unable to access the checkboxes using the handle from window.open. Any way to do this? var display; function showSugg(but_id, sugg1, sugg2, sugg3,...
2
1460
by: E. Paul Wileyto | last post by:
Can anyone help. I would like to create a table that contains references to a series of JPG files, so that I can view each image and related data in a form, page by page. It seems that the only...
5
3160
by: Alan Ho | last post by:
What are intrinsic objects of asp.net? thx
5
1485
by: Alex D. | last post by:
is there any way to automatically convert .net objects to javascripts objects? for example to send the bussiness logic to the browser and this way reduce the postbacks to the server? I think it...
1
1830
by: anagai | last post by:
Im wondering if generating html objects such as tabels and rows in javascript is faster than typing the html directly? Seems when you do it in javascript you have to download alot of code and would...
3
2093
by: kosmodisk | last post by:
Hi, I'm having problem accessing javascript-created elements from opened window. This occurs only when I'm including another files in opened window, javascript or css. When I comment out...
1
1290
by: Lorenzo Thurman | last post by:
I'd like for some elements to be draggable. I've found some code examples around the 'net on how to do this, but I have one requirement that none of them addresses: The item I need to move is a...
1
2693
by: elizayiu | last post by:
Hi, I need to write a webpage which does the following: - open up a window and pass parameters into it (i.e. need to call showModalDialog() or showModelessDialog()) - contains jscript to...
0
7134
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,...
1
6905
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
7395
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
5485
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,...
1
4921
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...
0
4609
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...
0
3108
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1429
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 ...
1
667
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.