Skip to content

Instantly share code, notes, and snippets.

@markSci5
Created July 9, 2013 03:19
Show Gist options
  • Save markSci5/5954429 to your computer and use it in GitHub Desktop.
Save markSci5/5954429 to your computer and use it in GitHub Desktop.
UIStoryboard controller instantiation
// Get the storyboard named secondStoryBoard from the main bundle:
UIStoryboard *secondStoryBoard = [UIStoryboard storyboardWithName:@"secondStoryBoard" bundle:nil];
// Load the initial view controller from the storyboard. // Set this by selecting 'Is Initial View Controller' on the appropriate view controller in the storyboard.
UIViewController *theInitialViewController = [secondStoryBoard instantiateInitialViewController];
// Then push the new view controller in the usual way:
[self.navigationController pushViewController:theTabBar animated:YES];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment