473,608 Members | 2,077 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Timing problem between frames

Don
From within the "main" frame, using JS, I'm trying to copy a couple variables and arrays from the
"header" frame into the "main" frame. I've incorporated a couple "alert" statements to test the
resulting data, and find that sometimes it's good and sometimes it's "undefined" . I'm thinking this
is a timing issue between the time the variables and arrays are resolved in the "header" frame, and
the time they are referenced in the "main" frame. There is no human intervention involved in either
frames, just the browsers load and execute times. How does one deal with this issue? Maybe, insert
a delay before the "main" frame is loaded or executed?

Thanks for any help.
Don

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
Jul 23 '05 #1
2 1140
"Don" <no@adr.com> skrev i meddelandet
news:ap******** *************** *********@4ax.c om...
From within the "main" frame, using JS, I'm trying to copy a couple variables and arrays from the "header" frame into the "main" frame. I've incorporated a couple "alert" statements to test the resulting data, and find that sometimes it's good and sometimes it's "undefined" . I'm thinking this is a timing issue between the time the variables and arrays are resolved in the "header" frame, and the time they are referenced in the "main" frame. There is no human intervention involved in either frames, just the browsers load and execute times. How does one deal with this issue? Maybe, insert a delay before the "main" frame is loaded or executed?

Thanks for any help.
Don


You mean, the main frame attempts to access stuff in the header frame before
the header frame has finished loading?

When the header frame finishes loading, you could have it set a flag
variable in the main frame. When the flag is set, you know it should be OK
to access stuff in the header frame. (You'll also need to check so that you
don't attempt to set the flag before the main frame has finished loading).

--
Joakim Braun
Jul 23 '05 #2
Don
On Sun, 20 Feb 2005 10:37:00 +0100, "Joakim Braun" <jo**********@j fbraun.removeth is.com> wrote:
"Don" <no@adr.com> skrev i meddelandet
news:ap******* *************** **********@4ax. com...
From within the "main" frame, using JS, I'm trying to copy a couple

variables and arrays from the
"header" frame into the "main" frame. I've incorporated a couple "alert"

statements to test the
resulting data, and find that sometimes it's good and sometimes it's

"undefined" . I'm thinking this
is a timing issue between the time the variables and arrays are resolved

in the "header" frame, and
the time they are referenced in the "main" frame. There is no human

intervention involved in either
frames, just the browsers load and execute times. How does one deal with

this issue? Maybe, insert
a delay before the "main" frame is loaded or executed?

Thanks for any help.
Don


You mean, the main frame attempts to access stuff in the header frame before
the header frame has finished loading?

When the header frame finishes loading, you could have it set a flag
variable in the main frame. When the flag is set, you know it should be OK
to access stuff in the header frame. (You'll also need to check so that you
don't attempt to set the flag before the main frame has finished loading).

Hi Joakim,

Thanks for your response. I tried what you recommended, but when I test the flag I get an
"undefined" error msg if the header frame isn't loaded and startup code executed, which of course I
don't want displayed to the client. So, I was thinking of trying to setup another almost unvisible
(only 1 pixel, borderless) frame that will maintain the interlock variable. That, combined with a
preferred frame load order, as indicated in the <frameset>, might take care of the problem. That
should get me away from the "undefined" problem. I'll give that a try later today.

Thanks for your help.
Don

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
Jul 23 '05 #3

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

Similar topics

5
2422
by: Leon | last post by:
Hi, Could you give me some suggestions or ideas for the loading speed difference between using one single frame for a web page and not using frame for this page? Thank you very much.
2
6461
by: ad | last post by:
What is the difference between iframe and frame? What is the situation to use iframe ?
12
2782
by: scsharma | last post by:
Hi, I am working on creating a webapplication and my design calls for creating main webform which will have menu bar on left hand side and a IFrame which will contain all the forms that are shown when menu items are clicked.Besides these i would like to put a custom status bar. Any error message encountered in any of the webpage will be displayed in the banner. The problem iam encountering is how to access the customer status bar in child...
1
351
by: FAQ server | last post by:
----------------------------------------------------------------------- FAQ Topic - How do I communicate between frames in a web browser? ----------------------------------------------------------------------- To reference another frame, you simply need to step through the frame hierarchy: `` parent '' is the page the frame is defined in, `` parent.framename '' is another frame in the same frameset. To access a variable called Moomin in...
1
2378
by: Mark London | last post by:
Can I pass $_SESSION variables between frames? Some web pages claim it is possible, but I tried setting $_SESSION in the parent frame, but the other frames didn't see it set. I'm using PHP5/apache. I've read that java can pass variables between frames, but how would I then see the java variable in the php code? Thanks very much.
0
972
by: CCG | last post by:
A have a web app in vb.net & asp.net. The page has 3 frames. a left frame shows options and never changes. The top right frame has paramter screen or a report. The bottom horizontal frame has different button(s) put on it depending on what is in the top right frame. If a parameter page shows, the button say RUN. The program then creates & shows a report & there are 3 buttons - export to Excel, to Word to PDF . All frames work...
15
2569
by: Jay | last post by:
I have a multi threaded VB.NET application (4 threads) that I use to send text messages to many, many employees via system.timer at a 5 second interval. Basically, I look in a SQL table (queue) to determine who needs to receive the text message then send the message to the address. Only problem is, the employee may receive up to 4 of the same messages because each thread gets the recors then sends the message. I need somehow to prevent...
5
1733
by: =?Utf-8?B?dWxpbGxpbGxpYQ==?= | last post by:
I've had two issues plaguing me for 4 months now and I haven't gotten anywhere. I'm into making 2D games and these things are essential to games. These are my issues: 1. I need timing precise to about 4 milliseconds at most. Currently, I've been using the clock() function, but it's only precise to 1/64 second (or about 15.6 milliseconds). For those running their monitor at 60 Hz, this isn't much of a problem, but for those running...
0
1931
by: Daniel Fetchinson | last post by:
On 4/15/08, Daniel Fetchinson <fetchinson@googlemail.comwrote: BTW, using the following ###################################################################### # CODE TO TEST BOTH FUNCTIONS back = fill_matrix(generate_zero())
0
8063
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
8498
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...
1
8152
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6014
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
5476
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
3962
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4025
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2474
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
1
1598
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.