Oogemaflip100
Oogemaflip100

Reputation: 47

What is the opposite to [sender resignFirstResponder]; Objective-C

Hi I was wondering if there was an opposite to

[sender resignFirstResponder];

I was wondering because I am doing a login page with 2 UITextFields ("username" and "password") and wanted the username done button to open the keyboard to the password field.

Maybe there's something like

[sender assignFirstResponder];

Thanks in advance!

Upvotes: 3

Views: 1558

Answers (3)

Siba Prasad Hota
Siba Prasad Hota

Reputation: 4789

if(textfield==nameTextfield)
{

[passwordTextField becomeFirstResponder];
}

Upvotes: 0

Mohammad Rabi
Mohammad Rabi

Reputation: 1412

you can use this

[myTextField becomeFirstResponder];

Upvotes: 1

Peter Warbo
Peter Warbo

Reputation: 11700

[sender becomeFirstResponder];

Upvotes: 14

Related Questions