Click here to Skip to main content
15,891,431 members
Please Sign up or sign in to vote.
0.00/5 (No votes)

Building a webapp for iPhone. I have tested that <input type="number" ... makes the iPhone display a numeric keyboard. How is that same behaviour created using <asp:TextBox?

It already works on the iPhone if I use HTML <input field. It should be possible using the asp:Textbox

Posted
Updated 1-Dec-09 5:04am
v3

If it's a webapp, then how can it be for iPhone particularly ? You can write javascript to only accept numbers, or use a validator control to enforce only numbers, but I don't think there's a quicker, built in way than that.
 
Share this answer
 
Try:
<asp:TextBox id="test" runat="server" pattern="[0-9]*" />


but is is working with safari 3.1 only! You should read apple reference for this.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900