Posted on 2006-11-26
I have a page in my application that has required fields on it. The required field validator work fine (client side) until I put the confirm function on the "onclientclick" attribute of the linkbutton.
when I click the submit link button with the js confirm script on the button, the confirm pops up but the validators do not show and if you click ok on the pop up the form submits even if the required field is empty.
linkbutton looks like this.
<asp:linkbutton id="lnkBtnSubmit" .... onclientclick="return confirmAction("Are you sure you want to submit this form. Click OK to proceed.")" onclick="lnkBtnSubmit_Click" />