Submit multipe forms with one submit button.

P

Paul M

Hi,
I've got a recordset consisting of many records (anything up to 250)
which currently loops to populate a form in each iteration. I need to
post the form to an external URL on each loop, or alternatively
populate multiple forms on one page and post each one in sequence.

The problem I've had is that the posting seems to be too quick and
only a handful arrive.

I can loop with an alert pop-up that prompts for the next send, but
it's v. inefficient. I'm told by some that it can't be done (don't
fully understand why), but my manager (who must be obeyed) says it
must be done.

Any thoughts?

PaulM
 
L

Lasse Reichstein Nielsen

I've got a recordset consisting of many records (anything up to 250)
which currently loops to populate a form in each iteration. I need to
post the form to an external URL on each loop, or alternatively
populate multiple forms on one page and post each one in sequence.

How are the forms created? You say that you "populate a form in each
iteration". What, *exactly*, is happening? Where is the code that
populates the form running? On the server or locally?

What happens when you submit one form? It is sent to a server that
returns a page which does what?

Do you control the platform that the forms are being submitted from?
The problem I've had is that the posting seems to be too quick and
only a handful arrive.

If you submit a new form with the same target as the old form, the old
request is interrupted. That can happen even before the requrest have
been sent, so the server never sees it.
I can loop with an alert pop-up that prompts for the next send, but
it's v. inefficient. I'm told by some that it can't be done (don't
fully understand why), but my manager (who must be obeyed) says it
must be done.

It sounds very much like a problem that is being attacked the wrong
way. If you can build a page that contains a form that must be
submitted, you should be able to send the contents directly to the
server without going through a browser.

Otherwise, you need to find a way to wait for the submit to complete
before submitting the next form. Since the form is submitted to a
different domain, cross domain scripting can make that hard. In IE,
you might use an HTML Application, which have extended scipting rights.

Or you could submit each form to a different target:

<form id="foo" target="tgt_foo" action="...">
....
</form>
<iframe id="tgt_foo" style="display:none"></iframe>

/L
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top