Hi!
In Aspnet, how to trigger RequiredFieldValidator when a textbox is clicked?
Hi!
In Aspnet, how to trigger RequiredFieldValidator when a textbox is clicked?
<asp:TextBox ID="TextBox1" runat="server" onclick="javascript:trig();"></asp:TextBox>
javascript funtion
function trig() {
ValidatorEnable(document.getElementById('<%= ValidatorID.ClientID %>'), true);
}
In ajax control toolkit, there is a control called validator callout that will help you to do this, link here http://www.asp.net/AJAX/AjaxControlToolkit/Samples/ValidatorCallout/ValidatorCallout.aspx