How do you use a custom validator? When might you want to
use one?
Answer Posted / pallavi
Field: <asp:textbox id="textbox1" runat="server">
<asp:CustomValidator id="valCustom" runat="server"
ControlToValidate="textbox1"
ClientValidationFunction="ClientValidate"
OnServerValidate="ServerValidate"
ErrorMessage="*This box is not valid" dispaly="dynamic">*
</asp:CustomValidator>
ClientValidationFunction is usually a javascript funtion included in the html to the user. OnServerValidate is the function that is server-side to check for validation if client does not support client-side validation.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is the difference between globalization and localization?
What is odata in web api?
Can anyone please tell me that the question posted on this website are Sufficient for the interview with 2+ year experience in .net
Explain the difference between array and linkedlist?
Define common type system?
Where would you use an ihttpmodule, and what are the limitations if any?
Define the types of configuration files.
Explain the difference between asp.net mvc and asp.net webforms? : asp.net mvc
What are the different authentication modes in asp.net?
What are the navigation ways between pages available in ASP.NET?
Explain managed code an un-managed code.
Which Is Faster MVC or ASP.net ?
What are triggers of an updatepanel?
is there any third party tools are using in .net technologies? what are there ? give me the brief introduction?
Define a static class?