Question Regular Expression

soni_1985

Member
Joined
Jul 11, 2009
Messages
8
Programming Experience
1-3
I want to enter only characters in textbox not numbers.For dat I use Regular Expression Validator,But even after dat numbers are entering.

VB.NET:
 <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox></td>
                     <asp:RegularExpressionValidator ID="regexpName" runat="server"     
                                    ErrorMessage="This expression does not validate." 
                                    ControlToValidate="TextBox1"     
                                    ValidationExpression="^[a-zA-Z'.\s]{1,40}$" />

I m take the help from the below site
How To: Use Regular Expressions to Constrain Input in ASP.NET

tell me one ting more frnds,we have grab the ValidationExpression or there is any logic behind it,I m just grabbing it.
 
Back
Top