I read a lot of thing, but anyone asked me. I am in a
(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;
So the user clicked in my tableView. I 开发者_高级运维am not in a UITextField. All I want is say to Keyboard screen go away animated, like when it close normally. How can I do this command:
[keyboard goway];
To dismiss the keyboard, you need to call resignFirstResponder. First though, you need figure out what object is first responder.
It's usually a textField, but it can be other things. For this example, you would call
[textField resignFirstResponder];
What object is using the keyboard? We may be able to help you further.
the UITableView should call becomeFirstResponder
Or, I guess a much easier way is not to rely on the UIKeyboardWillShowNotification, instead, you hijack the click event of the TextBox in your html, and run document.location = 'blablabla'; preventDefault();
, then your uiwebview delegate will knew it's time to call out the UITableView. This way is better because keyboard won't even show up.
精彩评论