S
Shawn Mehaffie
I have a form when the user clicks on a HTML Input control, a process runs
to submit the users order. While the process is running I wnat to disable
the button so the user cannot submit the form again. I have written client
side code to disable the button which is setup to run onclick. The client
side function runs (with alert but not code to disabel the button), then the
form is submitted and the ServerClick event is run. This is how it should
work according to the documentation.
The problem I am having is when I add the code to disable the sumbit button
then the server-side code does not run. Does anyone know of a way around
this? Is there a way to make the program run the server side code after
disabling the button?
I've tried to disable the button in the ServerClick event and run the
CCSubmit fucntion in a thread, but then the button disables properly but
does not enable correctly. The other important thing is that if there is an
error in the CCSumbit function I need to put the message in a label and make
the label visible. When I try this using a Thread the error message neve is
made visible either.
I really need an answer to his ASAP, so any ideas would be appreciated.
S. Shawn Mehaffie
PC Resources, LLC.
P.S. To me being the ability to run client-side and server side code the way
the documentation says should always run the server-side code, even if the
client-side disables the control. Other than validation code, the disabling
of the button that was pressed so users cannot press it again is a top use
for this feature. By not running the server-side code if you disable the
control you are putting a big limit on this.
to submit the users order. While the process is running I wnat to disable
the button so the user cannot submit the form again. I have written client
side code to disable the button which is setup to run onclick. The client
side function runs (with alert but not code to disabel the button), then the
form is submitted and the ServerClick event is run. This is how it should
work according to the documentation.
The problem I am having is when I add the code to disable the sumbit button
then the server-side code does not run. Does anyone know of a way around
this? Is there a way to make the program run the server side code after
disabling the button?
I've tried to disable the button in the ServerClick event and run the
CCSubmit fucntion in a thread, but then the button disables properly but
does not enable correctly. The other important thing is that if there is an
error in the CCSumbit function I need to put the message in a label and make
the label visible. When I try this using a Thread the error message neve is
made visible either.
I really need an answer to his ASAP, so any ideas would be appreciated.
S. Shawn Mehaffie
PC Resources, LLC.
P.S. To me being the ability to run client-side and server side code the way
the documentation says should always run the server-side code, even if the
client-side disables the control. Other than validation code, the disabling
of the button that was pressed so users cannot press it again is a top use
for this feature. By not running the server-side code if you disable the
control you are putting a big limit on this.