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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T11:10:47+00:00 2026-05-30T11:10:47+00:00

I have my app like this : a navigationBar in the app delegate with

  • 0

I have my app like this : a navigationBar in the app delegate with have a Controller1(UIViewController) like a rootController, in the controller1 i push controller2 ( UIViewController), the controller2 have 3 UINavigationController, and a Custom tabBar, each navigationController have a root controller, and finally i put all the navigationController in the CustomTabBar.

My question is : is this clean( good) to do like this ? If no how i can organize my project ?

MyAppDelegate.h 
@property (strong, nonatomic) UIWindow *window;
@property (strong, nonatomic) UINavigationController *navigationController;
@property (strong, nonatomic) CustomTabBar *tabBarController;

MyAppDelegate.m {
UIViewController *controller1 = [[UIViewController alloc] initWithNibName:nil bundle:nil];
    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
    // Override point for customization after application launch.
    self.window.backgroundColor = [UIColor whiteColor];
    navigationController = [[UINavigationController alloc] initWithRootViewController:controller1];
 self.window.rootViewController = navigationController;
}

controller1.h
    UIViewController controller2;
    UINavigationController *navigationController2;

    UIViewController controller3;
    UINavigationController *navigationController3;


    UIViewController controller3;
    UINavigationController *navigationController3;

controller1.m 
-(void)viewDidLoad{

viewController1 = [[UIViewController......
navigationController1 = [[UINavigationController alloc] initWithRootViewController:controller1];
....

AppDelegate *apDelegate= [UIApplication sharedApplication].delegate;

    apDelegate.tabBarController = [[CustomTabBar alloc] initWithNibName:nil bundle:nil];
   [apDelegate.tabBarController setViewControllers: [NSArray arrayWithObjects:navigationController1,navigationController2,navigationController3,nil]];
}
  • 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-30T11:10:49+00:00Added an answer on May 30, 2026 at 11:10 am

    This is an excerpt from the apple documentation:

    When deploying a tab bar interface, you must install this view as the root of your window. Unlike other view controllers, a tab bar interface should never be installed as a child of another view controller.

    From my point of view it’s a bit tricky from the start to sort out how to use UITabBarController class, so in this case the better approach is to see some good manual. For me this one helps always when I start to mess around with this UI thing 🙂

    Good luck.

    EDIT:
    In order to have your tabbar appear only in some concrete views, you have to hide your tabbar from the start of the app, and make it appear only when you really need it.
    In order to hide it, you can use the method:

    [theTabBar setHidden:YES];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

in my app i have an UITabBarController with UINavigationControllers initialized like this UINavigationController *newsNavigationController
I have a SQL query in my ASP.net web app that looks like this:
I have some code like this in a winforms app I was writing to
I have a Rack application that looks like this: class Foo def initialize(app) @app
I have a interface member like this. AppInterface.cs ObjLocation[] ArrayLocations { get; } App.cs
So I have this App in the store, and I would like to release
This is an interesting conundrum. We have a WPF app that has a Vista-like
I would like to have an app include a custom font for rendering text,
So, i got this Navigation-based App (with a custom NavigationBar - Category) and I
I have an app.config file, with app settings like this: <appSettings> <add key=setting1 value=1/>

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.