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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T15:41:21+00:00 2026-06-04T15:41:21+00:00

I am following the Big Nerd Ranch iOS Programming Guide(3rd Edition), and have followed

  • 0

I am following the Big Nerd Ranch iOS Programming Guide(3rd Edition), and have followed everything it says for creating this project. I am getting an error I do not know how to fix though, as I’m new to iOS. I was initially having a problem with my program giving me this error when I used Single-View Based Application from the template in Xcode:

2012-05-25 16:02:12.926 Whereami[1083:707] Application windows are expected to have a root view controller at the end of application launch

After scanning some forums I found out I need to set my MainInterface in Xcode:

Before – https://i.stack.imgur.com/BrKR1.png

After – https://i.stack.imgur.com/8BfgT.png

After fixing the error above by adding the xib filename to the MainInterface text box in the settings I am getting this error:

    2012-05-25 16:04:09.068 Whereami[1102:707] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<UIApplication 0x11f620> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key activityIndicator.
*** First throw call stack:
(0x3507b88f 0x364a2259 0x3507b5c5 0x30eb6323 0x30eb5e23 0x30e8ff09 0x34fda7d3 0x34fdb461 0x323111af 0x3231294d 0x32248509 0x320d1893 0x320cb8d7 0x32099c6b 0x3209970f 0x320990e3 0x362ce22b 0x3504f523 0x3504f4c5 0x3504e313 0x34fd14a5 0x34fd136d 0x320caa13 0x320c7e7d 0x7ebd7 0x7eb7c)
terminate called throwing an exception

Here are my source files:

AppDelegate.m – https://i.stack.imgur.com/548u4.png

WhereamiViewController.h
WhereamiViewController.m

View – https://i.stack.imgur.com/o5WYs.png

Run- https://i.stack.imgur.com/MLgKd.png

I am stumped, and need to figure this out so I can move on and eventually finish this book. I need to be able to complete my first app for work by next week.

  • 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-04T15:41:22+00:00Added an answer on June 4, 2026 at 3:41 pm

    The question text seems like you are asking this…
    One way you can set it is like this:

    - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
    {
        self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
        // Override point for customization after application launch.
        LoginViewController* loginView = [[[LoginViewController alloc]initWithNibName:nil bundle:nil]autorelease];
        mainNavController = [[UINavigationController alloc]initWithRootViewController:loginView];
    
        //here is the magic line
        [_window addSubview:mainNavController.view];
    
        [self.window makeKeyAndVisible];
        return YES;
    }
    

    Or you can do it without the mainNavController:

    - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
    {
        self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
            // Override point for customization after application launch.
        LoginViewController* loginView = [[[LoginViewController alloc]initWithNibName:nil bundle:nil]autorelease];
    
        [_window addSubview:loginView.view];
        self.window.backgroundColor = [UIColor whiteColor];
        [self.window makeKeyAndVisible];
        return YES;
    }
    

    The title seems like your asking this…
    Now the NSUnknownKeyException error usually crops up when you try to access a selector or a member of a class that does not exist or is spelled wrong (Usually the latter for me!). You can think of classes like a dictionary and calling a member, or function, is like asking for a dictionary object by it’s key.
    Ex.

    `@selector(misspelledFunctionName:)` 
    

    or

    [object functionThatIsMisspelledOrNotDefinedInObject];
    

    I am unsure which question is being asked so I tried to answer both. Hopefully that will help 🙂

    EDIT: These both ended up being the answer, or part of it anyways. The UIApplication did not have the correct view assigned to it so xib was sending keys that did not exist and caused it to crash. I removed the root view assignment from the plist (result no crashes but blank screen) then assigned the view like the above (the view displayed perfectly!).

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

Sidebar

Related Questions

I am following a book (Big Nerd Ranch IOS Programming) and the version of
Working off an idea from the Big Nerd Ranch guide to iOS programming, I'm
I am learning iOS programming through the Big Nerd Ranch guide by Hillegass and
I am following Big Nerd Ranch iOS Programming by Joe Conway and am kinda
I'm reading through the Big Nerd Ranch book on iOS programming and I had
For finding names in a big text I have the following regex ([A-Z][a-z]*)[\s-]([A-Z][a-z]*) This
I am following the BigNerdRanch iOS Programming book and I am on this one
I'm creating a Rails 3.1 app and I've the following big issue: I must
I have big dataset (but the following is small one for example). I can
I'm struggling with the following. If have a (big) data frame with the following:

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.