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

  • Home
  • SEARCH
  • 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 6198969
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T04:06:22+00:00 2026-05-24T04:06:22+00:00

I have a grouped table view that contains 3 sections and each row per

  • 0

I have a grouped table view that contains 3 sections and each row per section. The first two section rows contains UITextField(Name & Subject are the section titles) and the last one contains UITextView(Message is the section title) because i want to get some data from the user by this controller itself.

The two text fields have the returnKeyType as UIReturnKeyNext. For UITextView, the “return” button is present in keyboard to feed new line. So i used textFieldShouldReturn method to navigate to the next cell by pressing these return type buttons in UIKeyboard.

The next button will work fine with the first text field(Name). Here the problem comes… If i click the Next button of second cell, It goes to the UITextView(last cell) with one line down. That is, the cursor moves one line apart from its original position.

My code is…

-(BOOL) textFieldShouldReturn:(UITextField *)textField {
    [textField resignFirstResponder];
    if (textField == nameTextField) {
        [subjectTextField becomeFirstResponder];    
    }
    else if(textField == subjectTextField) {
        [messageTextView becomeFirstResponder];
    }
    return YES;
}

What should i do to make this work fine? Thanks in Advance..

  • 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-05-24T04:06:23+00:00Added an answer on May 24, 2026 at 4:06 am

    While testing a lot of stuff I found a simple yet suitable solution:

    - (BOOL)textFieldShouldReturn:(UITextField *)textField
    {
        if ( [textField isEqual: nameTextField] )
        {
            [nameTextField resignFirstResponder];
            [messageTextView becomeFirstResponder];
            return NO;
        }
    
        return YES;
    }
    

    It handles the resigning of the nameTextField itself and returns NO to the request.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a grouped table view that utilizes two different custom table cells. When
Quick one. I'm overlooking something... I have a grouped table view that is built
I have a grouped table view where I want to reload a particular row.
I have a grouped table view with textfields in the tableview. For the keyboard
I have a grouped UITableView that contains several cells (just standard UITableViewCell s), all
I have a Nib file containing grouped table view and a cell. The cell
I have a grouped table view and I don't want a see the background
I have a script that appends some rows to a table. One of the
I have a grouped table view which consists of custom cells. The problem is
I have a grouped table view; the table's background is a custom image. In

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.