.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Home >> Forum >> .NET Framework >> Post New QuestionBookmark and Share Subscribe to Forum

Regular expression validator for phone number

Posted By: softraj     Posted Date: July 05, 2010    Points:2   Category :.NET Framework
I want to use a textbox with regular expression validator to accept a land line number as well as mobile number. What is the validation expression for that? plz reply

Author: Syed Shakeer Hussain             
Posted Date: July 05, 2010     Points: 5   

uset the follwoing expression

<asp:TextBox ID="TextBox1" runat="server" ValidationGroup="check">

<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server"
ErrorMessage="Please Enter Only Numbers"
ValidationExpression="^\d+$" ValidationGroup="check">


Post Reply

You must Sign In To post reply
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more Here
Quick Links For Forum Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  OOPs  SilverlightIISJQuery

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend