Auto Capitalize UIKeyboardTypeNamePhonePad

I use UIKeyBoardTypeNamePhonePad to allow inputting only letters and numbers. I am missing some kind of functionality. First, I need all the letters that are printed on paper. I can simply change it, as it is included in the text view, but I do not want the user to get confused about how to enter capital letters. In addition, I want the number pad to appear on the first pop-up keyboard. Could you guys point me in the right direction how to achieve this functionality? The keyboard is used with the standard UITextField.

thank

+3
source share
1 answer

, UITextField UITextInputTraits. , :

[myTxtFld setAutocapitalizationType:UITextAutocapitalizationTypeAllCharacters];

:

[myTxtFld setKeyboardType:UIKeyboardTypeNumberPad];

: http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UITextInputTraits_Protocol/Reference/UITextInputTraits.html

+3

Source: https://habr.com/ru/post/1734174/


All Articles