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 8132293
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T09:18:49+00:00 2026-06-06T09:18:49+00:00

i have a UITableView with 3 UITableViewCells and 3 Picker Views with other data.

  • 0

i have a UITableView with 3 UITableViewCells and 3 Picker Views with other data.

Picker1 have Data1

Picker2 have Data2

Picker3 have Data3

this with the code:

- (NSString *)pickerView:(UIPickerView *)thePickerView titleForRow:(NSInteger)row      forComponent:(NSInteger)component;
{
if (thePickerView.tag == 1) {
    return [data1 objectAtIndex:row];
} else if (thePickerView.tag == 2) {

return [data2 objectAtIndex:row];        

} else if (thePickerView.tag == 3) {

    return [data3 objectAtIndex:row];

}
return [data1 objectAtIndex:row];

}

i want to change picker view’s data with a UITableViewCell. how i can do that?

  • 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-06T09:18:51+00:00Added an answer on June 6, 2026 at 9:18 am

    Do this create memberVariable NSIndexPath *selectedIndexPath in .h file and make its property.

    Now in tableViewDelegate method:

    - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
    {
        selectedIndexPath = [indexPath retain];
        //reload pickerview here
    }
    

    Picker View Delegate method will be like this:

    - (NSString *)pickerView:(UIPickerView *)pickerView 
              titleForRow:(NSInteger)row forComponent:(NSInteger)component 
    {
      switch (selectedIndexPath.row) 
      {
        case 0:
            //first cell selected picker view
            break;
        case 1:
            //second cell selected picker view
            break;
        case 2:
            //third cell selected picker view
            break;
         default:
         break;
      }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a UITableView of custom UITableViewCells which looks like this: [ CELL 0
I have UiTableView containing some data, and I want to scroll the UiTableViewCells horizontally
I have a UITableView with custom UITableViewCells , each of them has a UITextField
I have a UITableView with several UITableViewCells in it. I'd like to long press
I'm have a weird issue here. I have a UITableView using custom UITableViewCells. Everything
I have an UITableView which includes a list of UITableViewCells. And I set the
I have a UITableView of UITableViewCells that so far performed well. I now aded
I have a UITableView comprised of custom UITableViewCells with some text and a button
In my iPhone project I'm using a UITableview with UITableViewCells containing UITextfields. I have
I have a generic UISplitViewController (UITableView in the RootViewController and other stuff in the

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.