In my tab based application delegate i added the navigation controller as like the following,
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
UIViewController *viewController1 = [[FirstViewController alloc] initWithNibName:@"FirstViewController" bundle:nil];
UIViewController *viewController2 = [[SecondViewController alloc] initWithNibName:@"SecondViewController" bundle:nil];
UIViewController *viewController3 = [[view1 alloc] initWithNibName:@"view1" bundle:nil];
UIViewController *viewController4 = [[view2 alloc] initWithNibName:@"view2" bundle:nil];
UIViewController *viewController5 = [[view3 alloc] initWithNibName:@"view3" bundle:nil];
self.tabBarController = [[UITabBarController alloc] init];
self.tabBarController.viewControllers = @[viewController1, viewController2,viewController3,viewController4,viewController5];
navigationController=[[UINavigationController alloc]initWithRootViewController:self.tabBarController];
[self.window addSubview:[navigationController view]];
self.window.rootViewController = self.navigationController;
i would not be able to added the title in each view. While adding it doesn showing the title?Pls help me to resolve this issue
use bellow code…
Here i add
UINavigationControllerto every tab and also assign title for tab and also forUINavigationBarlike bellow…2)OR
Also you can simple assign title in your particular class like bellow…
i hope this helpful to you…