Its a server side validation control, this control can be used in VB or C# and one more thing u have to mainly specify the Validation Expression in the control property.
Numeric Validation : \d {3,5} -----> d -Numeric Checking, {} - Size
Character Validation : \D {5,10} -----> D - Character Validation, {} - Size.
how to make a validation like vb in asp.net? I want to make a text box should only accept numeric values....
samy
Hi,
First of all you need validation for textbox and you want user to enter only numeric values. So rather than allowing user to enter something and check it whether it is numeric or not is not good approach. I believe prevention is better than cure.
So you can Use FilterTextboxExtender that comes with AjaxToolkit. Please have a look at this demo
I hope this will solve your problem. You can use other tools also, they are very useful.
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Previous Thread in ASP.NET Forum Timeline:Web form