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 (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/development%40fornextsoft.com

This email sent to developm...@fornextsoft.com

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/brianslick%40mac.com

This email sent to briansl...@mac.com

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to