Mar 12, 2010, 2:20 PM
Postbacks and validation with toolbar buttons
I need to do a page postback on pressing a toolbar button, but having set Autopostback and CausesValidation to true, and set the button as a submit button, I find that the form isn't validated and just posts back. What's the best approach for doing validated postbacks with Coolite controls?
The only way I can see of achievng the desired behaviour it is to handle the button's client-click, and in the click handler, check the form panel's isValid() and then call doPostback() (or whatever it's called) to submit the form.
Is there a better approach?
The only way I can see of achievng the desired behaviour it is to handle the button's client-click, and in the click handler, check the form panel's isValid() and then call doPostback() (or whatever it's called) to submit the form.
Is there a better approach?