rkb
rkb

Reputation: 11231

How to get a Number key Pad with a point in iPhone

Hi I am using the following code for a text box

UITextField *txt_field = [[UITextField alloc] initWithFrame:frame];

[txt_field setKeyboardType: UIKeyboardTypeNumberPad];

Now When I click on the text field, a number pad comes up which dont have a decimal point option. I want a text field with just number pad where user can enter the number in decimal point also. I know I can use other pads but I dont want to allow user to have access to any other character keys other than number and a point. Is it possible.

tnx

Upvotes: 0

Views: 577

Answers (1)

Erich Mirabal
Erich Mirabal

Reputation: 10048

There are the built-in keyboard layouts or you have to roll your own.

Upvotes: 1

Related Questions