开发者

How to make the Number view in keyboard UITextField to become default?

I have a UITextField but my users will prefer enter some number in that field rather than typing text character (like enter a cost a product). So, how can I make the Number View in the keyboard to 开发者_运维知识库become default whenever the user tap into the UITextField?


In interface builder, just set the keyboard field of the UITextField to Number Pad.


You can also do it in code as UITextField conforms to the UITextInputTraits protocol (where you can set the keyboardAppearance and many other things).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜