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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T12:38:07+00:00 2026-05-16T12:38:07+00:00

I have a UITabbarController set by the Interfacebuilder. The tabbarcontroller has 5 tabs, the

  • 0

I have a UITabbarController set by the Interfacebuilder.
The tabbarcontroller has 5 tabs, the first is a welcome page, and the second is a UITableViewController. Both have a NavigationController. The 2nd tab should show a category list.
When I launch the app, all is fine. When I press the 2nd tab, it load the view perfectly with the navigation controller.
But what I want to do is to be able to load a certain category in the 2nd tab using a link in the first tab.

So what I did was I added the following function in my appDelegate and call is from the view in my first tab:

- (void)loadCategoryViewUsingCategoryId:(NSString*)categoryId
{
    CategoryViewController *categoryView = [[CategoryViewController alloc] initWithLoadingCategoryUsingCategoryId:categoryId];

    if (!categoryView) {
        UIAlertView *errorView;
        errorView = [[UIAlertView alloc]
                     initWithTitle: NSLocalizedString(@"Whoops", @"oddsAppAppDelegate")
                     message: NSLocalizedString(@"I did not found the requested category. Sorry!", @"oddsAppAppDelegate")
                     delegate: self
                     cancelButtonTitle: NSLocalizedString(@"Close", @"oddsAppAppDelegate") otherButtonTitles: nil];
        [errorView show];
        [errorView autorelease];
    }
    else {
        self.tabBarController.selectedIndex = 1;

        self.tabBarController.selectedViewController = categoryView;
        [self.tabBarController.selectedViewController setTitle:@"apa"];
        [self.tabBarController.selectedViewController viewDidLoad];
    }
}

This works perfectly, BUT… when the 2nd tab is loaded it doesn’t have the navigation controller toolbar. How can I load it so I keep my navigation controller toolbar?

The “CategoryViewController” is a UITableViewController by the way.

Best regards,
Paul Peelen

  • 1 1 Answer
  • 1 View
  • 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-16T12:38:07+00:00Added an answer on May 16, 2026 at 12:38 pm

    The Navigation Bar shall be visible by default. If you want to access it directly with

    [[self navigationController] setNavigationBarHidden:NO];
    

    I think your problem is somewhere else. If you assign your controllers like this

    UITabBarController *theTabBar = [[UITabBarController alloc]init];
    YourWelcomeViewClassHere *welcome = [[YourWelcomeViewClassHere alloc] initWithNibName:@"YourWelcomeViewClassHere" bundle:nil]; //Or other custom initalizers
    UINavigationController *welcomeNav = [[UINavigationController alloc] initWithRootViewController:welcome];
    CategoryViewController *category = [[CategoryViewController alloc] initWithNibName:@"CategoryViewController" bundle:nil]; //Or other custom initalizers
    UINavigationController *categoryNav = [[UINavigationController alloc] initWithRootViewController:category];
    /*
    Your other View controllers initializations
    */
    
    NSArray *viewControllers = [[NSArray alloc] initWithObjects:welcomeNav,categoryNav,/* other viewControllers ,*/nil];
    [theTabBar setViewControllers:viewControllers];
    

    This might work and show your views.

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

Sidebar

Related Questions

I have UITabBarController with 5 tabs, how can I set tabs titles while launching
I have a UITabBarController with a set of tabs. Some of them, when selected,
I have a UISplitViewController with the master view set up like this: UITabBarController Tab1:
I have a BaseViewController, which is a subclass of UITabBarController, and set up my
I have a UITabBarController with three tabs: each is a navigation controller with a
I have a UITabBarController, and all the VCs in the tabs use the same
I have a UINavigationController inside a UITabBarController. When a user presses the first tab,
I have an UITabBarController with two tabs: UINavigationController OptionsViewController : UIViewController How can I
I have an app which is a UITabBarController, I have defined two subviews Both
I have very unique problem. My app has UINavigationCnotroller with a set of UIViewController's.

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.