Hello,
I am moving my view when a text field is pressed in order to get proper view when keyboard appears. Now, when DONE key is presses I would like to return view to its initial state but, how to handle an action when done key is pressed?? Thanks
Hello,
I am moving my view when a text field is pressed in order to get proper view when keyboard appears. Now, when DONE key is presses I would like to return view to its initial state but, how to handle an action when done key is pressed?? Thanks
make an IBAction
as an IBOutlet
, and connect it to the text field's didEndOnExit
method
The proper way to do this is to observe to the notifications UIKeyboardDidShowNotification
and UIKeyboardDidHideNotification
as detailed in Apple's documentation.
If you want to know when the Done
button has been pressed, implement
- (BOOL)textFieldShouldReturn:(UITextField *)textField
In your delegate. It should be called when the return button is pressed. See API documentation for more details.
Thank you for your comments, I already solved handling didEndOnExit textbox method! Thanks again