views:

39

answers:

1

When I first launch the apps, I want it not to show the tab bar. Then after the user logins, it brings the tab bar. So how can I do this? Do I just hide the tab bar at first place then after the login succeed I will show the tab bar or I should have a UITabBarController inside the UIViewController for the first time?

A: 

If you push a modal controller over the tab bar to do the login it will cover the tabs.

[self presentModalViewController:loginViewController animated:YES]
blindJesse
can you give more details?
EquinoX
in the case above are you saying that the loginViewController will cover the TabBarController? How do I remove this loginViewController after a user logs in?
EquinoX
The easiest way is to load the tab bar controller, tabs, etc, then create the login controller inside of a navigation controller. show the navigation controller using the above method. when you are done using the login controller, dismiss it by having it call [self.navigationController dismissModalViewControllerAnimated:YES];
blindJesse