Re: Dismissing the iPhone keyboard
Re: Dismissing the iPhone keyboard
- Subject: Re: Dismissing the iPhone keyboard
- From: Brian Slick <email@hidden>
- Date: Fri, 03 Apr 2009 10:45:13 -0400
Do you have:
@interface YourViewController : UIViewController <UITextFieldDelegate>
^^^^^^^^^^^^^^^^^^^^^
...in your header file?
Oh, just glanced at my own code, and I'm using this when the text
field gets created:
[textField addTarget:self
action:@selector(textFieldDone:)
forControlEvents:UIControlEventEditingDidEndOnExit];
And this is the method:
- (void)textFieldDone:(id)sender
{
[sender resignFirstResponder];
}
Try that.
Brian
On Apr 3, 2009, at 9:30 AM, Development wrote:
I'm using
- (void)textFieldDidEndEditing:(UITextField *)textField
{
[textField resignFirstResponder];
}
and the matching method for the textview
I have set the delegate in IB and yet the note is never sent.
I can't figure out what I'm doing wrong.
On Apr 3, 2009, at 6:24 AM, Dave DeLong wrote:
Have the UITextfield resignFirstResponder. The keyboard goes away
when an editable element loses first responder status.
Dave
On Apr 3, 2009, at 6:49 AM, Development wrote:
How do I dismiss the keyboard from a UITextView when the cursor is
moved out?
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden