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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T09:02:19+00:00 2026-06-11T09:02:19+00:00

I am driving myself crazy over what I am sure is a basic error

  • 0

I am driving myself crazy over what I am sure is a basic error but I just can’t find it. I have simple delegates and everything works except this one. I can’t see any difference from the way I normally handle things.

@interface MasterViewController () <DetailViewControllerDelegate, SettingsViewControllerDelegate>

@end

@implementation MasterViewController

....

- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {

if([[segue identifier] isEqualToString:@"ShowSettings"]) {
    // here settingsViewController._delegate is 0x075...
    // why? where is this coming from?
    SettingsViewController *settingsViewController = [segue destinationViewController];
    // here settingsViewController._delegate is 0x00000 which I would expect
    [settingsViewController setDelegate:self];             
    // here settingsViewController._delegate is still 0x0000 -- why?
  }
}
  • 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-11T09:02:20+00:00Added an answer on June 11, 2026 at 9:02 am

    I fixed it. That took way too long. I’ve learned my lesson. Thanks Jon for reminding me to use the debugger!

        SettingsViewController *settingsViewController = [segue destinationViewController];        
        NSArray *childViewControllers = [NSArray arrayWithArray:[settingsViewController childViewControllers]];
        [[childViewControllers objectAtIndex:0] setDelegate:self];
    

    It works, but is this the right way to do it? [segue destinationViewController] was a UINavigationController.

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

Sidebar

Related Questions

I have been driving myself crazy to try to do what seems so simple.
I've been driving myself crazy over the past few days over this one. We've
This problem is driving me crazy because I am not sure why this just
This is driving me crazy... With this simple code I keep getting file not
This is driving me crazy. I have a PHP script that gets some data
This error is driving me crazy . I tried freenode #emberjs before asking here.
This is driving me mad so please help if you can... I have a
This has been driving me crazy for the past couple of hours. I have
I've been driving myself nuts with this and I'm hoping I'm just missing something
This is driving me crazy. I have an extension which we use to alter

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.