Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Explain what is the difference between odbc and ado?

1014


Explain the difference between task and thread in .net?

909


What are Satellite Assemblies? How you will create this? How will you get the different language strings?

1981


Explain what is immutability, what is it for and how is it codified?

1046


How will you do redo and undo in textbox control?

1016


What are data types in .NET?

1127


Explain the difference between garbage collections in .net 4.0 and earlier versions?

1024


How many types of transactions are there in com + .net ?

1040


explain the states of a window service application?

961


Is .net a programming language?

925


What is a windows process in .net?

1034


How can I get at the win32 api from a .net program?

983


What are the new features of Framework 1.1 ?

16613


What do you mean by Code Access Security in .NET?

1128


What is delegation in .net?

1054