Disable submit button after submission

We have a form that we have distributed to multiple users. The form is set so that submissions go to a pre-defined server location. The problem is that some of the users submit the form multiple times (not sure why). Perhaps they don't notice the message that says "Form submitted". In any case, we would like to disable the submit button after the form is submitted (even it is only for that "session"). I know that once the form is closed and reopened the button will work again and that is ok. If anyone has some suggestions I would appreciate it. Thanks.

hi,
modify the above script to:
this.access = "readOnly";
your submit button will be set to read only.
Regards--
Chalukya

Similar Messages

  • Disable submit button after clicking on it

    Hi all,
    I m beginner at working with JHeadstart.
    I searched through this forum but I couldn't find any solution for my problem,
    Now, i want to know how i can disable save button (or any other button) after clicking on it.
    I dont know, but It can be done by writing .vm, do u have an idea?
    Thanks for ur kind replies:)

    Hi,
    If you only want to be able to submit once you can add the following disabled property with EL expression to your save button in the jspx page.
    disabled="#{adfFacesContext.postback}"
    The save button will only be clickable upon initial entry of the page.
    To persist this change when generating your application you can use a custom velocity template. Have a look at the JHeadstart developers guide, paragraph 4.7
    http://download.oracle.com/consulting/jhsdevguide1013.pdf
    If you want to have an insert only form you can also use an insert only View Object (go to the view object editor and select the tuning tab and the "No rows" option)
    Regards,
    Ruud Bijkerk
    JHeadstart team

  • Disabling submit button after resetting the form.

    Hi. I'm new to JSF/Richfaces and there's something I'd like to do that I just can't figure out.
    Currently, I have a form with various fields to be edited, and the standard Submit and Reset buttons. The Submit button is disabled until a user changes a value on the form, and then I enable it using an A4J event. My problem is that I would like to disable the submit button again if the user clicks Reset. I'd like this to be completely client-side if possible, which I understand would require some javascript to implement, but I haven't been able to come up with a solution that works. Does anyone know how I could do this (with an example, preferably)?
    It's a pretty simple scenario, but here's the button code anyway:
    <h:commandButton id="submitButton" value="Submit" action="#{dataBean.submitForm}"
      disabled="#{! dataBean.pageEdited}" />
    <h:commandButton value="Reset" type="reset">
      <a4j:support event="onmouseup" reRender="submitButton" />
    </h:commandButton>

    I see, thanks! I looked up another example on using the DOM (I told you I was new!) and created the following javascript function, and it worked perfectly. I like that it automatically re-renders the button too so I don't need an A4J event.
    function disableSubmitOnReset(){
      document.getElementById('main_form:submitButton').disabled = true;
    }Definitely as simple as I figured it would be. :P

  • How to properly disable a button after click or can an event disable itself?

    Can I disable  MouseEvent.CLICK after I clicked it?
    I am relatively new to coding and it seems to me as a mistake that an event will disable itself?
    Is it ok or is it prone to some mistakes?
    mainNav_buttonsGroup_mc.Products_btn_mc.addEventListener(MouseEvent.CLICK, onClick_Products_btn);
              function onClick_Products_btn(event:MouseEvent) :void {
                        gotoAndPlay("products");
                        mainNav_buttonsGroup_mc.Products_btn_mc.removeEventListener(MouseEvent.CLICK, onClick_Products_btn);
      Products_btn_timeLine.play();
    The idea is that I want to disable a button after it is clicked.

    The approach will work.  The event is not disabling itself.  The event is the occurence of the CLICK interaction.  The event listener is designated to detect that happening.  The event handler function for that listener is disabling the event listener.

  • Spry validation disables Submit button

    Hey,
    I'm using spry validation on text boxes and dropdown menu's
    .. for some reason, on certain pages when the form is submitted and
    validated, if there's a problem with one of the fields, the submit
    button is disabled and won't enable again. Any ideas on how I can
    stop this from happening?

    Bump :o)

  • RESOLVED - iExpense: Disable Submit Button based on checkbox not working

    Hi,
    We have a requirement for a checkbox in iExpense Review form(FinalReviewPG) where there should be a checkbox stating the terms and policies are met etc. Unless the user checks the checkbox the SUBMIT button shouldnt be enabled. I am creating the custom checkbox using personalisation in the page with initial/unchecked value as N and checked value as Y. This is created at SITE level.
    Now I have also created a custom controller extension xxButtonCO to extend the standard ButtonsCO controller which should do the disable/enable of the button OIESubmit. I ported this controller to the custom top and have extended the controller to both OIE Expenses Entry Flow function and Internet Expenses responsibility. But the checkbox though visible is not affecting the SUBMIT button. Also funnily, I save the controller class as xx.oracle.apps.ap.oie.webui.xxlcButtonCO and click apply only to see this concatenated to apps.ap.oie.webui.xxlcButtonCO / Function.
    Is that causing an issue? Also, sometimes I just run into an arbitrary NULL pointer exception and other times it says oracle.apps.fnd.framework.OAException: Could not create Java class. I have verified the class file not java file is in correct directory and has right permissions.
    What could possibly be wrong here?
    Edited by: 865082 on Jun 15, 2011 5:33 AM
    Edited by: 865082 on 20/06/2011 22:21

    Hi Kali,
    Many thanks for your response. I have quit trying to run this page directly from the instance and am now trying to do this firsly from the JDeveloper. The same issue is occuring from that end as well. My checkbox value is not getting recognised in the code. The checkbox is added to the Business Expenses tab and the intial/unchecked value is N while the checked value is Y. I am trying to control the submit button in the buttonbar based on the checkbox value using the following command
    OAMessageCheckBoxBean cbbean = (OAMessageCheckBoxBean)webBean.findChildRecursive("XXReviewCheck");
    where XXReviewCheck is the checkbox ID. However the print statements show that the cbbean is null. It is definitely calling the controller and trying to figure out the value. The value is just not coming to this section. Any ideas?

  • Custom validation is disabling submit button

    Hi there,
    I am using the update/insert feature within ADDT, but wanted to use my own validation using JavaScript. Everything works fine, the validation pop-up works etc, but the submit button is disabled. I'm guess that the transaction has started with the ADDT, but the javascript has stopped it. How can I get around this? any suggestions welcome...
    Thanks in advance...

    Hi,
    Have you tried different browsers to double check. I remember a couple months ago I was helping someone with a similar problem, it worked in one browser fine but not the other so we had to rewrite the code. Initially the code looked fine but just didnt work in IE.

  • Disabled Submit Button

    At the time of submit the submit button is disabled. Is there a way to disable this functionality for certain form?

    by default, on nextensio forms, it is done automatically, but what you seek is done by javascript. something like:<br /><br />I found this here: http://www.houseofscripts.com/scripts/javascripts/disablebut.htm <br /><br />As you can see, this code allows us to do disable any button - either Submit or Button.<br />Just add onClick="Disab (1)" <br /><HTML><br /><HEAD><br /><br /><SCRIPT LANGUAGE="JavaScript"><br /><br />function Disab (val) {<br /><br />if(val=="1") <br />{form1.Submit.disabled=true}<br /><br />if(val=="2") <br />{form1.Button.disabled=true}<br />}<br /><br /></SCRIPT><br /><br /></HEAD><br /><BODY TEXT="000000" BGCOLOR="FFFFFF"><br /><br /><FORM name="form1" method="post" action=""<br />enctype="text/plain"><br /><input type="submit" name="Submit" value="Submit" onClick="Disab (1)"><br /><input type="button" name="Button" value="Button" onClick="Disab (2)"><br /></FORM><br /><br /></BODY><br /></HTML>

  • How to disable a submit button on click using javascript

    Hi,
    We have built custom pages for mobile device (PDT) using OAF.
    The application is running on mobile IE 6.12 browser. In mobile platform, the cursor style is not changing to hour glass upon clicking.
    Due to this, user is able to click the same button multiple times before the operation is complete and it is getting submitted multiple time. But the same is working fine in Desktop browsers.
    We have tried with ((OABodyBean)body).setBlockOnEverySubmit(true); But the API documentation states that
    "Sets If set to true, user input will be blocked after EVERY submit (not just PPR submits). This attribute is not supported on the following agent types: pda, phone, voice."
    Hence, I am trying with javascript to disable the submit button after the first click. The issue is, even in the desktop browser
    I am not able to get the button disabled after first click. Please help me.
    I have tried the following statments in PR. But none of them seems to be working.
    //Try 1: directly using id
    OASubmitButtonBean updBtn = ((OASubmitButtonBean)webBean.findChildRecursive("UpdateBN"));
    updBtn.setOnClick("document.getElementById('UpdateBN').disabled=true;document.getElementById('UpdateBN').submit()");
    //Try 2:
    OASubmitButtonBean updBtn = ((OASubmitButtonBean)webBean.findChildRecursive("UpdateBN"));
    updBtn.setOnClick("javascript:this.disabled=true;this.form.submit();");
    //Try 3:
    OASubmitButtonBean updBtn = ((OASubmitButtonBean)webBean.findChildRecursive("UpdateBN"));
    updBtn.setOnClick("this.disabled=true;this.form.submit();");
    //Try 4: using a function
    static final String JS_MULTI_CLICK = "<Script LANGUAGE=\"JavaScript\"> "
    +" function DisabSub(btn)"
    + "{"
    + "btn.disabled = true;"
    + "}"
    +" </Script>" ;
    OARawTextBean rawMultiClick = (OARawTextBean)webBean.findIndexedChildRecursive("JSMultiClick");
    rawMultiClick.setText(JS_MULTI_CLICK);
    OASubmitButtonBean updBtn = ((OASubmitButtonBean)webBean.findChildRecursive("UpdateBN"));
    updBtn.setOnClick("javascript: var obj =disable(this);return DisabSub(obj);");
    Can any one please help.
    Thanks in advance.
    Regards
    Saravanan

    Hi,
    Create two submit buttons A and B adjacent to each other.
    On page Load ,make A as rendered false and disabled true and B as rendered true. using SPEL.
    now on click of button B make button A as rendered true and Button B as rendered false through SPEL.
    In this way on button click the button will become disabled without the use of any javascript.
    Try it if it helps you...
    Thanks,
    Gaurav

  • How to disable the submit button

    Hello ,
    I have multiple controls on a page . I want to disable submit button until the user enters all the fields .
    How to do this . appreciate your help in this .
    rgds
    kumar

    Hi Kumar,
    watch this post: disabling the submit button
    Tobias
    http://apex-at-work.blogspot.com

  • How to disable submit more than once?

    Hi,
    I have a form with a huge number of fields and validations on their validate event.
    The form has a submit button with the following routine:
    myDoc.submitForm(
         cURL: URL,
         cSubmitAs: "PDF"
    My goal is that the user will be able to submit the form only once.
    If I hide the submit button after this script there is a chance that one of the fields not pass the validation, the button disappear and user is not able to submit any more.
    Otherwise nothing avoid from the user to submit the form multiple times.
    Anyone has an idea?

    here you can use
    if()
    else if()
    else if()
    else
      write code that you want to execute in last.
    Untill top conditions are not satisfied, code below that condition will not be executed. So no need to disable submit button because when user will click on submit button it will check all the condition from top.
    Thanks

  • Double Click handling with Submit Button

    Does a submitButton on the page automatically handle / block the user's double click action?
    I have an application where a submit button causes processing & commits to occur.
    I want to make sure that when the user "double-click" the button, it doesn't cause problems.
    Thanks

    Hi
    Does a submitButton on the page automatically handle / block the user's double click action?No it doesnot handles so..
    You can write the below code in processRequest method of your controller to disable the button till the moment processing is going on,After processing completes you can again click submit button.
    OAWebBean body = pageContext.getRootWebBean();
    if(body instanceof OABodyBean)
    ((OABodyBean)body).setBlockOnEverySubmit(true);
    }Please refer to this article for more details
    http://mukx.blogspot.com/2009/12/blocking-user-on-submit-action-in-oaf.html
    Moreover,if you want to disable the button after first click then on click of get an event redirect it to same page and make it disabled or use Partial page rendering for this.
    Thanks
    AJ

  • How to prevent multiple clicks of submit buttons in OAF Pages

    Hi All,
    Our page takes around 30 seconds to 1 minute for processing.
    Some users are not patient enough. I have tried putting the below code in my PR method.
    OAWebBean body = pageContext.getRootWebBean();
        if (body instanceof OABodyBean)
        ((OABodyBean)body).setBlockOnEverySubmit(true);
    This code disables submit button for some time. After few seconds, the submit button can be clicked again by the user.
    Also, if I click on other browser window and come back to OAF page, the submit button can be clicked again immediately.
    Have also searched OAF forum but didn't find any satisfactory answer.
    Need answer from Oracle on this. If not answered on the forum, will raise an SR.

    Hi Amit,
    Try using the Processing Symbol , after clicking the Submit button. Which does shows you processing clock symbol once you click Submit Button.
    Regards
    Raghu

  • Hiding submit button from an Infopath form in a Sharepoint Library document

    I have a Sharepoint document library that is setup to collect submissions from a form that faces the public.  Because it faces the public it needs to have the standard/familiar submit button.  The problem is that when the form is submitted to the
    document library and the document is reviewed, it still contains the button - which will be confusing/complained about by staff.
    I attempted to use a hidden boolean field that would switch to "True" when the submit button is clicked and then use conditional formatting to hide the button before submitting through the data connection.  But apparently, there is no way
    to move the conditional formatting rules after the action rules that make the boolean swith.
    I then tried to switch to a new view that was identical to my Main view before submitting but the button is still appearing on the submitted documents in the form library.
    I'm wondering if anyone has experience with this?  I have to think I'm missing something obvious.

    Please try this -
    https://social.msdn.microsoft.com/Forums/en-US/5767ff6c-764d-479c-904e-22e40a697c6c/how-to-hide-custom-submit-button-after-form-has-been-submitted-infopath?forum=sharepointcustomizationlegacy
    Thanks
    Ganesh Jat [My Blog |
    LinkedIn | Twitter ]
    Please click 'Mark As Answer' if a post solves your problem or 'Vote As Helpful' if it was useful.

  • What is the property to disable a button in a module pool program?

    Hello Experts,
    I want to disable the button after inserting the record in a Z Table.
    Can you please help me.
    Thanks,
    Manisha

    HI,
    I tried , as you people told. But i am not getting it.
    In my module pool I wrote like this:
    REPORT  ZTRY_BUTTON.
    tables : zmani_emp.
    data: itab like zmani_emp OCCURS 0 with HEADER LINE.
    *&      Module  USER_COMMAND_2000  INPUT
    *       text
    MODULE USER_COMMAND_2000 INPUT.
      case sy-ucomm.
        when 'OK'.
          insert into zmani_emp values itab.
        when 'CANCEL'.
          leave program.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_2000  INPUT
    now plz tel me wat shud I have to do??
    thanks
    manisha
    Edited by: PATIL MANISHA on Apr 30, 2010 11:43 AM

Maybe you are looking for