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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T08:28:00+00:00 2026-05-30T08:28:00+00:00

I am learning iOS and I have written a simple iPhone app using iOS

  • 0

I am learning iOS and I have written a simple iPhone app using iOS 5. The app shows a UITableView populated with Speakers’ names, when I select one of the names its supposed to go to a UIViewController and show details about that person (name, address, etc), so its really two ViewControllers a UITableViewController and UIViewController (both subclassed).

So, in MICSpeakersTableViewController : UITableViewController I have this:

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    MICSpeakerDetailViewController *detailViewController = [[MICSpeakerDetailViewController alloc] initWithNibName:@"Detail" bundle:nil];    

    [detailViewController setSpeaker:[[self getSpeakers] objectAtIndex:indexPath.row]];
    [self.navigationController pushViewController:detailViewController animated:YES];    
}

which gets called when I select it and populates the speaker (in that its not nil and description matches).

Then I have this in the same implementation:

- (void) prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
{
    NSIndexPath *indexPath = [ self.tableView indexPathForCell:sender];

    if ([segue.identifier isEqualToString:@"Detail"])
        [segue.destinationViewController setSpeaker:[[self getSpeakers] objectAtIndex:indexPath.row]];
}

Which also gets called and the segue.identifier is Detail and the destinationViewController’s speaker is set correctly (is not nil, description matches). I am not quite sure why I have to set that again since I am setting it in didSelectRowAtIndexPath but I set it again and it seems harmless.

Finally, in the MICSpeakerDetailViewController, the initWithNibName method is called and the self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; returns an instance.

However, the segue never happens and viewDidLoad is never called.

Its probably something small but I can’t figure it out… any advice?

Edit: Here is a screenshot of the storyboard showing the segue and the controllers:

enter image description here

  • 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-30T08:28:01+00:00Added an answer on May 30, 2026 at 8:28 am

    You have to embed the view controllers in a navigation controller for push segues to work. I don’t know why it lets you define them without this in place.

    To do this, click on your table view controller, then choose Editor –> Embed In –> Navigation Controller. If you should also be within a tab bar controller, then the navigation controller is embedded in that in a similar fashion. You should see the following:

    enter image description here

    Your segue will now work.

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

Sidebar

Related Questions

I am learning to develop iPhone applications using iOS 5. I am trying to
I am learning to write an iOS-native webkit app. In Xcode 3.x, I have
I'm just getting started learning CoreData for iOS and have written some exploratory code
I am just starting climbing the Objective C learning curve (using Nerd Ranch iOS
I have started to build my own apps on iPhone and iPad using the
I am currently using IOS SDK 4.0.2 and learning how to do UIAutomation. Unfortunately
I am learning iOS development in Objective-C, and I have found a lot of
I'm interested in learning IOS programming but at the moment i do not have
I am attempting to create a simple iOS application, mostly for the learning process,
I am very new to iOS Programming and have been learning for only a

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.