0

I am using storyboards. From ViewController1, I segue to ViewController2 using a modal segue programmatically:
[self performSegueWithIdentifier: @"ViewController2" sender: self];.

At the end of ViewController2 execution, I want to go back to the first view controller using∫br>[self dismissViewControllerAnimated:YES completion:nil];
and receive an EXC_BAD_ACCESS message.

Reading the numerous articles on this issue, the statement seems to be that the initial view controller is deallocated. However none of the articles I found explains how to prevent this deallocation and how to anyway come back.

Any help appreciated !

4

1 回答 1

1

您不能self用于解雇。使用self.presentingViewController.

于 2013-04-13T20:17:08.930 回答