for the textbox if i want to allow only numbers.what ever
the characters u enter it should not take.which event u used?
Answer Posted / chandra sekhar
@kinjal what is the use of using compare validator here??
and with what yopu are comparing the value?? your answer is
absolutely wrong.
If we want to allow only integers into a textbox then use
"^\d{0,9}" expression.
ex: <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<asp:RegularExpressionValidator
ID="RegularExpressionValidator1" runat="server"
ControlToValidate="TextBox1"
ErrorMessage="RegularExpressionValidator"
ValidationExpression="^\d{0,9}"></asp:RegularExpressionValidator>
Is This Answer Correct ? | 11 Yes | 1 No |
Post New Answer View All Answers
What are the differences between com architecture and.net architecture?
Explain something about WebService?
What are the namespace available in .net?
Whate are resource files?
Tell us what is heap and what is stack?
What does jit compilation do in .net?
i m fresher,hav SQL knowledge but in my ofc. i hav to work on dotnet. so plz tell me how to learn it,? from where to stat? i hav C prog. knowledge, ASP.net
What is close method? How its different from finalize and dispose?
What are the new thee features of com+ services, which are not there in com (mts)?
How does u handle this COM components developed in other programming languages in .NET?
Difference between class and interface in .net?
Why did they call it .net?
Explain about the features and elements present in Visual studio.NET IDE?
Explain what is the difference between encrypting a password and applying a hashing?
Explain what is the difference between response.redirect & server.transfer?