How can I show the numeric keyboard by default on iPhone?

Viewed 47824

I'm trying the following with no luck. When the user click on a UiTextfield I need to change the keyboard view to the numeric view automatically, is this possible?

6 Answers

it is a good practice to always write the parent class UIKeyboardType and then continue with the keyboard enum numberPad

myTextField.keyboardType = UIKeyboardType.numberPad
Related