Accept auto-correction after input

My user enters text in UITextField

, then press a UIBarButtonItem

to confirm.

If there is an auto-correct suggestion when the user clicks UIBarButtonItem

, it is not accepted. How can I accept it programmatically?

+2


source to share


1 answer


Try to call:

[textfield resignFirstResponder];

      



in the text box when the user clicks the button.

+3


source







All Articles