Within my app i have 2 storyboards, one has all the configuration screens and the other has the main screens of the app.
In one of the main screens of the app the user can press a button which allows them to go back and edit or add anything to the configuration.
The issue is if the user came from the main screens, once they press the done button on the configuration screen to confirm their changes, is there a way i can segue back to the main screen storyboard and then segue to the screen they were previously on before going to configuration ?
You need to have code to transition between the storyboards.
- (IBAction)showNextStoryboard:(id)sender
{
UIStoryboard *nextStoryboard = [UIStoryboard storyboardWithName:@"SecondStoryboard" bundle:nil];
UIViewController *nextRoot = [nextStoryboard instantiateInitialViewController];
[self presentViewController:nextRoot
animated:YES
completion:^{}];
}
And to return:
- (IBAction)returnToPreviousStoryboard
{
[self.presentingViewController dismissViewControllerAnimated:YES completion:^{}];
}