Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8123601
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T06:13:52+00:00 2026-06-06T06:13:52+00:00

I have 2 textfields, for login id and password. When user taps on email

  • 0

I have 2 textfields, for login id and password.
When user taps on email id, they keyboard type is email and for password, its default.
They done button of both the keyboards, dismisses the keyboard.
WHat i am trying to do is, once user fills both the id and password, they DONE button should be changed to “LOGIN” and i can perform selector method on it to login.

Can this be doable?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T06:13:53+00:00Added an answer on June 6, 2026 at 6:13 am

    If you are using standard iOS keyboard, then the only available return key type is

    typedef enum {
        UIReturnKeyDefault,         // “Return”
        UIReturnKeyGo,              // “Go”
        UIReturnKeyGoogle,          // “Google”.
        UIReturnKeyJoin,            // “Join”.
        UIReturnKeyNext,            // “Next”.
        UIReturnKeyRoute,           // “Route”.
        UIReturnKeySearch,          // “Search”.
        UIReturnKeySend,            // “Send”.
        UIReturnKeyYahoo,           // “Yahoo”.
        UIReturnKeyDone,            // “Done”
        UIReturnKeyEmergencyCall,   // "Emergency Call”.
    } UIReturnKeyType;
    

    To detect the keychange on the keyboards you can register for name:UITextFieldTextDidChangeNotification . Lets say your textfield are emailTextField and passwordTextField.

    First you register the notification, the detect the text input

    // emailTextField
    [[NSNotificationCenter defaultCenter] addObserver:self 
                                             selector:@selector(check)
                                                 name:UITextFieldTextDidChangeNotification
                                               object:emailTextField];
    
    // passwordTextField
    [[NSNotificationCenter defaultCenter] addObserver:self 
                                             selector:@selector(check)
                                                 name:UITextFieldTextDidChangeNotification
                                               object:passwordTextField];
    
    - (void)check {
      if ([emailTextField.text length] > 0 && [passwordTextField.text length] > 0) {
         // Set the return key here, e.g:
         emailTextField.returnKeyType = UIReturnKeyGo;
         passwordTextField.returnKeyType = UIReturnKeyGo;
      }
      else {
         // Set the return key here, e.g: 
         emailTextField.returnKeyType = UIReturnKeyNext;
         passwordTextField.returnKeyType = UIReturnKeyNext;
      }
    }
    

    When the return key tapped, it’ll call textfield delegate. You can do something like this:

    - (BOOL)textFieldShouldReturn:(UITextField *)textField
    {
        // You can perform selector here, probably after checking if both of the textfields already filled   out. E.g:
        if ([emailTextField.text length] > 0 && [passwordTextField.text length] > 0) {
            [self performSelector:@selector(login)];
        }
    
        return YES;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a login screen with two textfields (username and password). When the user
I have a text input which has a default value password. When the user
I have a login view with username & password textfields and two buttons for
I have two textfields in HTML, when a button is clicked, I need to
In my iPad app I have two textfields. One displays the normal, default textfield
I have a simple rails webpage where a user enters in a few textfields
I have a file holding default information that I use to load the textFields
I have 2 text fields, user and password. When I enter the password, it
I have a simple login form that has 2 text fields and a button.
I have a popup which asks the user for login information, which means two

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.