Reputation: 14662
My user enter a text in a UITextField
then press a UIBarButtonItem
to confirm.
If there's a autocorrection suggestion when the user tap the UIBarButtonItem
, it is not accepted. How do I accept it programmatically?
Upvotes: 2
Views: 241
Reputation: 39376
Try calling:
[textfield resignFirstResponder];
on your textfield, when the user hits your button.
Upvotes: 3