I just tried double clicking and did not get two jobs - also, if i disable
the submit button, how would they use a mouse to submit the form?


Larry Kleinman
Kleinman Associates, Inc.
212-949-6469
203-255-4100


                                                                       
             <Matt.Haas@thomso                                       
             n.com>                                                  
             Sent by:                                                    To
             web400-bounces@mi         <web400@xxxxxxxxxxxx>         
             drange.com                                                  cc
                                                                       
                                                                    Subject
             08/17/2006 11:32          Re: [WEB400] duplicate jobs in  
             AM                        net.data                      
                                                                       
                                                                       
             Please respond to                                         
             Web Enabling the                                          
              AS400 / iSeries                                          
             <web400@midrange.                                       
                   com>                                                
                                                                       
                                                                       




Double clicking the submit button will cause the form to be submitted
twice. You should disable the submit button in your JavaScript.

Matt

-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx]
On Behalf Of Larry Kleinman
Sent: Thursday, August 17, 2006 11:07 AM
To: web400@xxxxxxxxxxxx
Subject: [WEB400] duplicate jobs in net.data


Hello all - from time to time (but not always) one instance of my
net.data
macro starts 2 concurrent jobs doing the same thing.  Both run under the
QTMHHTTP user profile, in the DEFAULT instance of the HTTP server
(original,
not Apache).  There is only one user running these macros, so there is
no
way that two people did the same thing at the same time.   The macro
does
have a button that submits the form, and also has an "onkeypress" that
submits the form if ENTER is pressed.  (The code is below).  I thought
that
maybe this could make the form get submitted twice, but it doesn't
happen
all of the time.  Anybody have any ideas?

%MACRO_FUNCTION S1 () {

<head>
      <title> Shop Metal Entry </title>

<script language=JavaScript>
 function SubmitForm(Action) {
 document.S1.action = Action;
 document.S1.submit ();
 }
 </script>

<script language=JavaScript>
function CheckEnter( ) {
if (window.event && window.event.keyCode == 13)
     SubmitForm('Edit1');
  else
    return true;}
</script>

<BODY OnLoad="document.S1.VDStNo.focus();document.S1.VDStNo.select();">

  <h2>  Shop Metal Entry </h2>

<form method="POST"
      name="S1"
         onkeypress="CheckEnter ( )"  >



  <table border="1"
         frame="below"
         rules="none"
         cellpadding="1"
         width="70%">

    <tr>
    <td>
      Stock Number


  </td>
  <td>
   <input type="text"
          NAME="VDStNo"
          VALUE="$(VDStNo)"
          MAXLENGTH="6"
          SIZE=6>

  </td>
  </tr>


</table>


  <BR>

<input type="button" value="Continue"
       onclick="SubmitForm('Edit1')">





Larry Kleinman
Kleinman Associates, Inc.
212-949-6469
203-255-4100
--
This is the Web Enabling the AS400 / iSeries (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.


--
This is the Web Enabling the AS400 / iSeries (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.


This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2020 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].