views:

638

answers:

1

I'm working on an iPhone app with only one view, a UITextView, and I want it to launch all ready for typing (with the keyboard activated) but by default it requires the user to first tap the view before the keyboard appears. I've seen this done in other applications but haven't been able to figure it out. Thanks.

+4  A: 

you need to use the -becomeFirstResponder method on your field:

[myTextField becomeFirstResponder];

This will pop the keyboard up. To hide the keyboard, use -resignFirstResponder.

Ben Gottlieb