473,701 Members | 2,466 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

a question about auto submit to a frame

Hi,
There are two frames in an asp page.When a frame loads,I submit a form
to the other frame in onload event.Sometimes the code works fine,but
sometimes it will submit to a new window.
Why does it happen? how to resolve it?

Thanks in advance!

jack
Jul 19 '05 #1
1 1502
simply means that the other framewasn't loaded yet, so it didn't really
'exist'

make sure that 'the other frame' is loaded before you try posting to it...

do something like
if (window.FRAMENA ME) {
do_submit_funct ion()
} else {
setTimeout("thi s_function()", 2000)
}

so if 'the other frame' isn't loaded yet, it'll wait 2 secs and try again...

careful tho, coz it'll keep trying so make sure that 'the other frame' WILL
be there.

cheers and good luck

"jack.lee" <le***@21cn.com > wrote in message
news:O5******** ******@TK2MSFTN GP09.phx.gbl...
Hi,
There are two frames in an asp page.When a frame loads,I submit a form
to the other frame in onload event.Sometimes the code works fine,but
sometimes it will submit to a new window.
Why does it happen? how to resolve it?

Thanks in advance!

jack

Jul 19 '05 #2

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

Similar topics

4
29591
by: Scott Castillo | last post by:
Does anybody know how to auto-submit a form in PHP without Javascript? For instance, submit form variables to self, validate the data in PHP on same page, then, if no errors, auto-submit the data via post rather than URL. Could serialize a few fields to URL, but there is a larger comments field that I think needs to be posted instead. Auto-post the form variables possible? Thanks,
0
6257
by: Stephen Witter | last post by:
I have two asp pages. Both have similar purposes. I am trying to get the inline frame in both pages to update (submit) when a user clicks on a drop-down box (I would prefer the change or after update events but couldn't get them to work the way I wanted) This process works for one page but not thte other I am using frontpage. Here is the code for both: Page 1 - doesn't work <base target="ViewArticleSelect"> (My inline frame page)
2
18343
by: Halldór Ísak Gylfason | last post by:
In my application I have an iframe that is empty (and not visible) initially, however when a user presses a button a form is programmatically submitted and the target is set to the IFrame. I want to detect when the frame has been loaded with the result of the form submit. Of course I have tried some event handlers like onload, onactivate, onreadystatechange, but they do not work in this example. They only seem to work, when the "SRC"...
2
2247
by: Colin McKinnon | last post by:
Hi all, I've got two frames, one with a form ('main') and one with some clickable images ('tp'). The clickable images call a function in 'main' (code below) which in turn calls the .submit() or .reset() methods of the form. The submit call does what is expected. But the reset call throws an error in Mozilla (1.2.1) 'widget.reset is not a function'. It doesn't work in Konqueror (3.1.1) either (don't have an error message - it just don't...
0
1135
by: tony wong | last post by:
i have a page with top frame (html) and bottom frame (asp) the top frame come with choices and then submit value to bottom asp page by submit button how can i do it if i wish the bottom asp to run automatically in specific value when the html is loaded. then the user can change the choices after.
5
10982
by: Scott | last post by:
How can I tell a form to submit itself in the code-behind in vs.net? In other words, in javascript I can do blah.submit() - how do I do this in vs.net code-behind?
3
1741
by: Robin | last post by:
Hi, I have a question: If I have a frameset, frame1 and frame2. On frame2 I have a datagrid, on which I can add/update/delete rows. If I submit that page, I catch these changes in events and update my objects with it. Now do I want a button in frame1, which does save. The problem is that I first want to submit the page in frame2 to update my objects, before
3
7546
by: Larry | last post by:
I have a page that uses 2 frames. In the upper frame are buttons that add text things to the form text boxes in the lower frame using javascript. The form is then submitted to another page. Is it possible to have a Submit button in the upper frame that will submit the form in the lower frame? Thanks much, Larry
4
5958
by: malambing57 | last post by:
How do I submit using framet set. I want the top frame to submit the form on my bottom frame when time is up. On my top frame, I have the following code; if((min == 1) && ((sec >= 8) && (sec < 9 ))) { document.frames.form1.action = "testBody2.asp"; document.frames.form1.target = "mainFrame"; document.frames.form1.submit(); }
0
9223
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
9083
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...
1
8975
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,...
0
8934
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7822
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...
0
4410
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
4662
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3102
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
2398
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.