I am trying to build an application for iphone with using storyboard that starting with login screen and after user touch the login button, it should check it with authentication method. But, i could not directly link the login button to UITabBarController, because when user touch the button it directly goes the Tab Bar page without checking the login method. And also i tried to create mytabBar class it extends from UITabBarController and I set UITabBarController in custom classs as mytabBar in storyboard. Then I putted in my login view controller class;
#import "tabBar.h"
- (IBAction)loginCheck:(id)sender{
tabBar *tabbar = [[tabBar alloc] initWithNibName:nil bundle:nil];
[self presentModalViewController:tabbar animated:YES];
}
but it still does not working.
What type is
tabBar? There is nocheckin this method. Maybe do:… in the method to be sure it gets called.
Whenever you are working with
UIStoryboardyou are doing something like this instead of initializing a new instance oftabBar:… The identifier can be found in the
ViewController'sInspector-Tab in IB.