How to enable or disable the keyboard back key

When we enter a character in the text box, it includes a return key. But in our requirement, we need to include a return key when the length is greater than 5. But now, as soon as we enter the character, it activates the return key. Do I need to customize the keyboard or is there any other solution. Thanks in advance.

+3
source share
1 answer

Well, I think you should handle it in a UITextField UITextField :

 - (BOOL) textFieldShouldReturn:(UITextField*) textField { return textField.text.length > 0; } 
-2
source

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


All Articles