Reputation: 614
Please refer to the image below -
I'm not using NavigationViewController. Is there a way to switch between views when using storyboard and segues? I know the other way around would be to use a root view controller and switch views that way. Just wanted to know if there is a alternative way of doing this.
Thanks!
Upvotes: 2
Views: 1203
Reputation: 437882
You can either:
Use a navigation controller, but just hide it (both in the Interface Builder design of the storyboard, as well as programmatically at runtime via setNavigationBarHidden:animated:
in your viewDidLoad
). Thus pushViewController
(or a simple push segue) and popViewController
work, without the navigation bar user interface.
Use modal segues (i.e. behind the scenes it will do presentViewControllerAnimated
) and dismissViewControllerAnimated
.
Upvotes: 1
Reputation: 4797
It does not require a navigationController to use a segue. Just use the [self performSegueWithIdentifier:@"mySegue" sender:sender];
line anywhere you have a Segue set up and identified in your Storyboard.
Upvotes: 1