Exforsys
+ Reply to Thread
Results 1 to 4 of 4

Disable a button

This is a discussion on Disable a button within the Microsoft .NET forums, part of the Programming Talk category; I have a Save button on a web page. I want to disable the button when clicked, so that the ...

  1. #1
    sansircar is offline Junior Member Array
    Join Date
    Oct 2006
    Answers
    2

    Unhappy Disable a button

    I have a Save button on a web page.
    I want to disable the button when clicked, so that the user does not click it more than once, as the serevr side code is being processed.
    i disabled the button by calling a javascript function -
    btnSave.Attributes.Add("onClick","return buttonDisabled();") ;

    In the Javascript file i have -
    function disableButton()
    {
    var btnSave = document.getElementById('btnSave') ;
    btnSave.disabled = true ;
    return true ;
    }

    since the button gets disabled my server side code(in C#) does not get executed.
    thanks a lot for any kind of help


  2. #2
    JohnDoe is offline Junior Member Array
    Join Date
    Feb 2007
    Answers
    14
    Apologies but I seem to have missed what you need help on. Please clarify


  3. #3
    compad is offline Junior Member Array
    Join Date
    Mar 2007
    Location
    India, Gujarat
    Answers
    3

    Use Enable Properties

    Dear Friends,

    Try enable properties of button

    Thanks,
    Adarsh Patel



  4. #4
    arunns007 is offline Junior Member Array
    Join Date
    Jan 2011
    Answers
    1
    Visibility of the button can be set to false after the button click


    •    Sponsored Ads



Latest Article

Network Security Risk Assessment and Measurement

Read More...