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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T00:03:15+00:00 2026-06-11T00:03:15+00:00

So, I started developing an app in an entirely view-based way in Xcode 3.2.5

  • 0

So, I started developing an app in an entirely view-based way in Xcode 3.2.5 and then upgraded to Xcode 4.4. I have one NIB file (well two, MainWindow.xib and my default view controller’s .xib). I have a bunch of view controllers that up til now I’ve been presenting via presentModalViewController.

The problem is that now I want one of those views to be navigation based, which is to say, when the user enters it, they get the top navigation bar, and everything they get to from that point forward is done through a navigation controller. And when they’re done and have backed out of it completely, they get back to the regular non-navigation-controller-using views.

It seems like this is a common question that no one has fully described the answer to. Either that or responses which seem helpful like How to add a navigation controller to a view-based application? are way too vague for me. I’m basically looking for a step-by-step explanation of how you add a UINavigationController to your project for presenting only a few of the views in it.

  • 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-11T00:03:17+00:00Added an answer on June 11, 2026 at 12:03 am

    If you already have your view working as you intended it, adding a nav controller to modal view is pretty simple.

    NewViewController *newView = [[NewViewController alloc] initWithNibName:@"NewViewController" bundle:nil];
    UINavigationController *navView = [[UINavigationController alloc] initWithrootViewController:newView];
    [self presentModalViewController:navView animated:YES];
    

    Your modal view will inherit the navigation bar and all the attributes for presenting more views inside that modal. When you are done with the modal, just dismiss it.

    To load more views on top of the nav controller is pretty easy.

    AnotherViewController *anotherView = [[AnotherViewController alloc] initWithNibName:@"AnotherViewController" bundle:nil];
    [self.navigationController pushViewController:anotherView animated:YES];
    

    To manually pop the view controller from the stack:

    // note, you won't need to call this for the auto created back button, that is handled for you
    // this would only be if you wanted manual control over going back outside the back button
    [self.navigationController popViewControllerAnimated:YES];
    

    Once you are all done with the modal view, you can call this from anywhere to drop it out of sight, returning you to your original view. Handy for multiple detail screens, signup process, etc.

    [self.navigationController dismissModalViewControllerAnimated:YES];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am developing a GPS-based app and have just started adding in my UX
I started developing an android app that have to interact with MMS attachements, in
Yesterday I have started developing my first Metro style App using JavaScript. I've used
I have started developing a new Rails app on my server using RVM, Rails
Am learning AppEngine and have started developing new app and want to clarify something.
I'm started off developing a facebook application. One of the requirements is to have
I have just started developing a Grails app froma tutorial today, and I have
I am just getting started developing my first Android app, and one function that
Since I've started developing my Blackberry app, the biggest problems I've encountered all had
I'm developing an Android app, and due to time circumstances, I started developing 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.