How to disable button immediately after click?

Hello,
I'm using JDeveloper 11.1.1.4.0
On my screen is an 'Add' button that calls specific method written in bean (addAction). Following are actions in addAction():
1. Disable Add button
2. Execute 'CreateInsert'
3. adfContext.addPartialTarget(corresponding adf table)
This works fine when user clicks on 'Add' and waits for couple of seconds, till the 'Add' button gets disabled
However, if the user keeps on clicking 'Add' button, it sends multiple requests to server and adds those many records in 'adf table'.
Is there any way to stop user input till the response is received for the previous request?
I tried setting up 'blocking' property of the button. But it did not work.
I also tried using 'unsecure' property of the button for disabled property and call setProperty('disabled',true) in javascript. In this case server request is not sent.
Appreciate your help in this regard.
Amar

hi user,
i cant undertud ur problem.. but i understud that something disabing the button.
<af:commandButton text="Entry completed" id="cb23"
binding="#{pageFlowScope.managedbean_GeneralLedger.cb23}"
action="#{pageFlowScope.managedbean_GeneralLedger.cb23_action2}"
disabled+="#{bindings.GlLvlAccounts1.estimatedRowCount eq 0 ? 'true' : 'false'}" // here whatever ur condition.
partialSubmit="true"
/>
af:command button disabled

Similar Messages

  • How to disable button immediately after pressing

    Hi
    In my save button there is a code for insertion of data in database.
    In my application when i press save button first time the IE progress bar shows progress but if suppose the user presses the button again
    then the data wil get saved twice.
    Now if i put a code in button action method to disable it will function only when it will be called in between user can press the button.
    How to arrest users for clicking???
    If you have any idea please help me out.

    How about setting the button to:
    yourButton.setVisible(false);
    So when your button action is called, this is the first action that is called before your code insertion lines so the button will disappear when clicked e.g.
    public String yourButton_action {
    yourButton.setVisible(false);
    ....code insert data......
    return null;
    Or set the "return null" to return a new page.
    Of course, if you wanted it to be visible again after the insertion then you would set
    yourButton.setVisible(true);
    Alternatively, you could setup a counter that would check the number of times the button was pressed and make the button visible (or invisible!) when conditions are met.

  • How to disable button once user click once in an Applet?

    Hi,
    We are facing an issue with Applet level button.
    User is clicking multiple times on button and we don't want to allow users to click multiple times.
    So that How to disable the button after clicking once.
    Thanks,
    Sandep.

    Since you don't saying what version of Siebel you are on, I assume
    8.0 or later.
    You can use this on if you applet class is CSSFrame, CSSFrameList, or any of their subclasses.
    On the applet add, Applet User Prop:
    Name
    CanInvokeMethod: InvokeWF
    Value
    [DisableButton]='N' OR [DisableButton] IS NULL
    More info here:
    http://download.oracle.com/docs/cd/B40099_02/books/ToolsDevRef/ToolsDevRef_UserProps6.html
    On the applet add, Applet User Prop:
    Name
    Named Method
    Value
    "InvokeWF", "SET", "DisableButton", "Y"
    More info here:
    http://download.oracle.com/docs/cd/B40099_02/books/ToolsDevRef/ToolsDevRef_UserProps21.html
    Make sure the field DisableButton is active (Use Force Active on BC if the field isn't active)
    Make sure the field has "Immediate Post Changes" set to true on the BC.
    Axel
    PS: Don't use scripts if you can solve the problem with user props, WF, .... Scripting should
    be you last resort.

  • Hi all, how to dubug an application after clicking ok button on popup

    Hi all, how to dubug an application after clicking ok button on popup, pcan anyone give me the porcedure
    Regards,
    Sre

    Copy the below text into a notepad file and save.
    [FUNCTION]
    Command=/H
    Title=Debugger
    Type=SystemCommand
    Now when you get a popup and want to debug from the same, drag & drop the saved file on to the popup window and debug starts right after the next user-command.

  • How to disable buttons in HTML?

    How to disable buttons in HTML?
    For example.. In my application when one button is clicked then it should disable some buttons and should be able to perform any other actions...

    Correct me if i am wrong.. i think we should not use '[' but '('
    document.getElementById('buttonname').disabled = true;

  • How to disable openGL in after effects cs6?

    I have posted a previous discussion, but I don't know why, no one is answering me and it's really annoying. Please, please, please, I can't wait anymore, tell me how to disable openGL in after effects cs6
    windows 7 SP1 64 bit, ati radeon 5570, 6 Go ram, 4 core processor 2.8 GHz, creative x fi sound blaster.

    This is the other discussion: http://forums.adobe.com/message/4518765#4518765
    I've tried to lower the quality, and with pure magic, it now works, even when I put highest quality. I don't understand what happened. I asked you how to disable openGL because they told me to in the last discussion. So, thank you for repairing my problem (I think you repaired it, i'll make tests to see). Just in case, could you verify if it's posible to disable openGL like the other person told me?

  • Disable button when user clicks

    Hi.,
    I am using jdev 11.1.5
    I need to disable button when user clicks the record which contain the value 'No'
    My scenario
    Id          Value
    1            Yes
    2            No
    3            YesThe button should get enabled for the first record which contain value 'Yes'
    In the above table the button should get enabled for
    Id        Value
    1          Yes          //while user clicks the record button must enabledfor 2 and 3 the button must be disabled
    could any one pls help me

    Hi,
    First get the selected value in bean and set it to String attribute,in your value change listener.
            public void customVLC(ValueChangeEvent valueChangeEvent) {
              //write code to get selected value
              this.selectedValue = "No";//Depend on your selected value on above
              AdfFacesContext.getCurrentInstance().addPartialTarget(getCbButton());//Bind button to bean and get UI here to refresh
       private String selectedValue;
        public void setSelectedValue(String selectedValue) {
            this.selectedValue = selectedValue;
        public String getSelectedValue() {
            return selectedValue;
        }in page put as
    disabled="#{YourBean.selectedValue eq 'No' ? true : false}"Here selectedValue keep the state for disable and enable the button
    I hope above information enough to resolve the issue..

  • Firefox 8 Crashes immediately after clicking the icon. (Won't load safemode either)

    Firefox 8 crashes immediately after clicking the icon. It does not even show the windows for a second. It immediately goes to the crash reporter. I tried holding shift while opening firefox to load safemode, but the problem is still there.
    Crash report:
    AvailableVirtualMemory: 4075601920
    BuildID: 20111104165243
    CrashTime: 1325436524
    InstallTime: 1320870265
    ProductName: Firefox
    ReleaseChannel: release
    SecondsSinceLastCrash: 336
    StartupTime: 1325436519
    SystemMemoryUsePercentage: 81
    Throttleable: 1
    TotalVirtualMemory: 4294836224
    URL:
    Vendor: Mozilla
    Version: 8.0
    This report also contains technical information about the state of the application when it crashed.

    See also [[Latest Firefox issues]] and http://kb.mozillazine.org/Firefox_crashes#Crash_when_starting_Firefox
    (For the record) "More system details" includes the crash Report ID:<br>
    bp-22454cd4-00b4-489f-bb8a-509772120101
    Crash Report: https://crash-stats.mozilla.com/report/index/bp-22454cd4-00b4-489f-bb8a-509772120101
    Firefox 8.0 Crash Report [@ JSObject::getGlobal() ]

  • How to disable the form after i click a link in WAD

    Hi All,
    I have a WAD template where there are a lot of hyperlinks and buttons present to enable the control to go to same or different templates. What I want to achieve is once i click on a hyperlink, the whole form should get disabled so that I may not be able to click on any other link until the control goes to a different page. I tried using document.form.disabled = true which though gives the look and feel of the form as disabled after click of the link but still doesn't stop me to click other links.
    I also tried document.form.getElementById("Id").disabled = true for the links but still the same thing happens.
    The above commands work fine if i use them outside WAD, but don't seem to work in WAD.
    Any thoughts?
    Gaurav Jasoria

    Hi Friends,
    This is really urgent.Can you please suggest me a way out.
    Regards,
    Gaurav Jasoria

  • How make a button inactive after the click ?

    Hi,
    how can i make a button inactive after i clik on it ? I need it becasue i have one button which play my symbol (made with this nice course https://blogs.adobe.com/edge/2012/07/18/tutorial-leveraging-independent-symbol-timelines/) but it's not working when the button is in the symbol where there is animation, it's only working when the buttons is a symbol on the stage and on the top of all over symbols, so when i clik on it works and play the symbol that i want but after is still active so i can't place another button at the exact same place of the first because it will play the first button and i need to put 20 buttons, anyone can help me please ? My buttons is just an empty rectangle so i don't talk about turn of the visibility but turn of th "activity"
    Thanks a lot

    If you prefer you can put the code in compositionReady
    Here is a sampe on how to use a next and prev buttons to change data.I have some other examples I will add later but this one could give you an idea on how to do it.
    This one uses data from an array and then moves through the info:
    https://app.box.com/s/78ya0labbydgwogxra2a
    If you are playing symbols then use the rigth scope to get to them.
    I would make a array of the symbol names and use it the same way like I did the array for the info.
    sym.getSymbol(mysymbolArray[i]).play();

  • How to: disable buttons in standard forms

    Hi all,
    does anybody know how to disable session date button from standard forms?
    I cannot find in forms (through Form Builder) the right data block / canvas where this button is.
    Thanks all.
    Jacopo

    I'm not aware of any "session date button". A button on a form can be disabled using the set_item_property.
    Use the layout editor and double-click the button. It will tell you what button it is. The button will also be highlighted in the Object Navigator window.
    Message was edited by:
    Mark Roberts

  • How to display a table after clicking on a chart in ssrs?

    Hi all experts,
    I need to display a table control after clicking on a chart. 
    I was looking for the visibility property of the table which can be set based upon click on the bar chart.
    Please respond asap...

    Hi Manisha,
    If I understand correctly, you want to control the table visibility through clicking the chart. In this case, please refer to the detailed steps below:
    1. Create the parameter named Control, check the Boolean option in the drop-down list of the Data Type, and select Hidden in the parameter visibility tab.
    2. Specify the default value of the parameter to True.
    3. Click the series in the chart and select “Action” in the Properties pane and click the ellipsis as follows:
    4. Select the “Go to report” tab, and select the self-report in the “Specify a report” tab.
    5. Pass the parameter as bellows:
      Name:Control  Vaule:false
    6. Right click the table control, select Tablix Properties and select the Visiblity property.
    7. Select the tab of Show or hide based on an expression, and add the expression below:
    =iif(Parameters!Control.Value=true,true,false)
    If you need more assistance, please feel free to let me know.
    Regards,
    Heidi Duan

  • How to disable Buttons based on condition.

    Hi
    Need your help to disable button based on condition.
    Please refer the application:
    http://apex.oracle.com/pls/otn/f?p=34797:5:110582943383419::NO:::
    login credentials:
    workspace: vsanthanam
    user: vijay
    pswd: apex_demo
    In the above application, i have 2 buttons in page 5, (Report1 and Report2)
    Where i have to disable button based on the following conditon:
    i) USER whoever has Admin value 'Y' in my table can access the button.
    for this i've written a Button Condition : Type (EXISTS)
    select 1 from apex_extra_values where rtrim(lower(empname)) like decode((select Admin from apex_extra_values
    where rtrim(lower(empname))=rtrim(lower(V('APP_USER')))),'Y',rtrim(lower(V('APP_USER'))))
    note: i have empname same as my APEx user name. with Admin access 'Y'.
    By using this code i can able to hide the button for users who has no Admin access.
    But my requirement is : i have to show the button even if the user is not Admin, but to grey out (disable the button - no action)
    I tried using javascript function:
    function disableButton(pThis)
    pThis.disabled=true;
    But either of this (exists condtion or JAvascript function) works in my case and not both.
    Any pointer on this would be highlt appreciated.
    Thanks
    Vijay

    Couple of things:
    1. I would never use v('APP_ITEM') but :APP_ITEM - it is faster and there is no need to use this function within an application
    2. The way you are doing this check is not the best approach. You should create an authorization schema and run this once per session. Whatever this authorization is returning as a result you can check using the following Function returning boolean:
    IF apex_util.public_check_authorization ('MY_AUTH') THEN RETURN TRUE; ELSE RETURN FALSE; END IF;
    See this example on authorization issues:
    http://apex.oracle.com/pls/otn/f?p=31517:148
    3. As far as disabling a button is concerned I think I explained the options. I also have an example on that here:
    http://apex.oracle.com/pls/otn/f?p=31517:143
    whereby it is not disabling but hiding a button.
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.opal-consulting.de/training
    http://apex.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • How to Group Subfolders Immediately after Folder

    When I open Documents (in list view) I find all subfolders listed with files (alphabetically). So if I am looking for a subfolder I need to scroll to find it (among all other files in Documents). Is there a way to group all Subfolders (immediately) after the Documents folder? And is there a way to show the subfolders so that they are not expanded? I have been through my Mac OS X for Dummies book and this Forum but I can not find an answer. Thanks.

    Actually it will work in column view as of Leopard. Apple added this with Leopard: when you are in column view select "Show View Options" and you'll notice a new "Arrange By" option that lets you sort column view by Name, Kind, Size, Dates or Label. I don't use it much as I tend to forget to reset it and then get confused next time I open a window in column view and automatically look for something by name and don't see it....
    Francine
    Francine
    Schwieder

  • How to disable buttons in ADF form so it can be reused

    I would like to reuse the same Human Task ADF form for multiple User Activities in the same BPM 11g process definition.  The only difference between the User Activities in the process are the outcomes (buttons) allowed.  For example, in some User Activities, the outcomes allowed are APPROVE and REJECT.  In others, it might be APPROVE, REJECT, and REPROCESS.  Is it possible to hide, or disable, buttons in a Human Task ADF form based on some settings done in the User Activity, or something passed to the Human Task ADF form?
    I started digging, and I see in the jspx file for the form, there is an attribute named "visible" that is set as follows on the button:
    <af:commandToolbarButton actionListener="#{invokeActionBean.setOperation}"
                           text="#{wf:getResourceValue('APPROVE', 'bindings.customActions')}"
                           disabled="#{!bindings.APPROVE.enabled}"
                           action="#{invokeActionBean.invokeOperation}"
                           partialSubmit="false"
                           visible="#{wf:isCustomActionAvailable('APPROVE', 'bindings.customActions')}"
                           id="ctb2">
        <f:attribute name="DC_OPERATION_BINDING" value="bindings.APPROVE"/>
    </af:commandToolbarButton>
    So if I can figure out a way to pass flags to the form, and then use those in the setting of the "visible" flag, would that do it?  Is there a better method?
    Thanks,
    Joe A.

    Set the binding to the button in the managed bean based on the input form parameter. For example if parameter value is paramValue1
    <task-flow-definition id="sourceTaskflow">
      <input-parameter-definition>
          <name>inputParameter1</name>
          <value>#{pageFlowScope.paramValue1}</value>
          <class>java.lang.String</class>
       </input-parameter-definition>
    </task-flow-definition>
    Set binding to not enabled.
    #{!bindings.CreateInsert.enabled}
    Some relevant references
    http://www.oracle.com/technetwork/developer-tools/adf/learnmore/oct2010-otn-harvest-183714.pdf
    Using Parameters in Task Flows

Maybe you are looking for