How do you use a custom validator? When might you want to
use one?
Answers were Sorted based on User's Feedback
Answer / sravanthi kilari
Insert Custom Validator Control and then write the custom
function. If Other Validation Controls did't meet our
requirement then we will go to Custom Validator Control.
| Is This Answer Correct ? | 4 Yes | 1 No |
Answer / 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 |
Answer / santosh bind
when using the complex validation like text should not contain the max 50 char
protected void cusCustom_ServerValidate(object sender, ServerValidateEventArgs e)
{
if(e.Value.Length == 10)
e.IsValid = true;
else
e.IsValid = false;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
In which form does the dataset store data in it?
3 Answers Verinon Technology Solutions,
How many types of sessions are there?
What is application variable in asp.net?
Types of session management in ASP.NET ?
Is asp.net mvc front end or backend? : Asp.Net MVC
What is the use of location tag in web.config file
2 Answers Karur Vysya Bank KVB,
How to implement caching?
what is session . how it is use ?
What is validation in asp.net?
When was asp.net released?
Explain program to call the js function when the change is being made in the dropdown list made in asp.net mvc? : asp.net mvc
What is the difference between adding reference in solution explorer and adding references by using ?
Visual Basic (800)
C Sharp (3816)
ASP.NET (3180)
VB.NET (461)
COM+ (79)
ADO.NET (717)
IIS (369)
MTS (11)
Crystal Reports (81)
BizTalk (89)
Dot Net (2435)
Exchange Server (362)
SharePoint (720)
WCF (340)
MS Office Microsoft (6963)
LINQ Language-Integrated Query (317)
WPF (371)
TypeScript (144)
Microsoft Related AllOther (311)