Disable/Hide button when opening Dialog Box through ASP.NET

Discussion in 'ASP .Net' started by microsoft, Oct 5, 2004.

  1. microsoft

    microsoft Guest

    I am looking for code for a button on a website, and I want it to prevent
    users from clicking more than once while their request is being processed. I
    would like it to disable or hide the button once clicked and then enable it
    after the process is completed from either the server or a web dialog box.

    I did find a sample on disabling the button while the server is processing
    their request and the sample was found here:

    http://www.codeproject.com/aspnet/ClickOnce_Button_Control.asp

    It worked perfectly, but not if the button was clicked for a popup. I did
    find code to show a modal dialog box, but that popup wouldn't display the
    Acrobat file at all (I know, a real pain). The link for the code I found is
    located here:

    http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=2282&lngWId=10

    Is there any sample code to disable a button OR display a separate popup
    form module that can show an Acrobat file and not allow the user to go to
    the main form until the Acrobat document is taken care of first?

    I wish I could show what code I have so far but company policy won't allow
    me to do that.

    Impossible?

    TIA
     
    microsoft, Oct 5, 2004
    #1
    1. Advertising

  2. microsoft

    bruce barker Guest

    you should do the detection on the server side. what will you do if the user
    hits the button, but the request never gets to your site? what if your site
    recycles during the request? what if your site processed the request, but it
    never made it back to the client? the internet is not a reliable transport,
    you have to code for lost and duplicate requests

    -- bruce (sqlwork.com)


    "microsoft" <> wrote in message
    news:...
    > I am looking for code for a button on a website, and I want it to prevent
    > users from clicking more than once while their request is being processed.

    I
    > would like it to disable or hide the button once clicked and then enable

    it
    > after the process is completed from either the server or a web dialog box.
    >
    > I did find a sample on disabling the button while the server is processing
    > their request and the sample was found here:
    >
    > http://www.codeproject.com/aspnet/ClickOnce_Button_Control.asp
    >
    > It worked perfectly, but not if the button was clicked for a popup. I did
    > find code to show a modal dialog box, but that popup wouldn't display the
    > Acrobat file at all (I know, a real pain). The link for the code I found

    is
    > located here:
    >
    >

    http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=2282&lngWId=10
    >
    > Is there any sample code to disable a button OR display a separate popup
    > form module that can show an Acrobat file and not allow the user to go to
    > the main form until the Acrobat document is taken care of first?
    >
    > I wish I could show what code I have so far but company policy won't allow
    > me to do that.
    >
    > Impossible?
    >
    > TIA
    >
    >
     
    bruce barker, Oct 5, 2004
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mullin Yu
    Replies:
    1
    Views:
    366
    Steve C. Orr [MVP, MCSD]
    Nov 26, 2003
  2. Brian Takita
    Replies:
    1
    Views:
    350
    Brian Takita
    Feb 3, 2004
  3. Sankar
    Replies:
    0
    Views:
    386
    Sankar
    Apr 22, 2004
  4. bienwell
    Replies:
    5
    Views:
    5,207
    bienwell
    Aug 13, 2006
  5. yw
    Replies:
    3
    Views:
    820
    Phlip
    Jul 2, 2005
Loading...

Share This Page