0

I have a master view, I have added in a menu (TableView) that slides out on an IBOutlet. This menu is controlled by another view controller. The master view is segued to multiple other views but I am having huge problems segueing from the menu view (TableView) because it is in another view controller.

How can I segue from master view to another view from my table which is controlled from yet another view controller?

Note: I am also having to carry over some information from master view to the other views, but I when ever I have tried to segue from the menu, the new views error and tell me they unexpectedly found nil while unwrapping optionals.

2
  • Can you post the Prepare for segue method here ? and one screen shot of your story board ? Commented Aug 11, 2015 at 19:44
  • sometimes it is easier to present a view modally rather than segue Commented Aug 11, 2015 at 19:45

1 Answer 1

1

Have your menu only post a notification when something is selected. Have the view controller that's the source of the segue (master?) listen for the matching notification(s) and perform the segue.

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you, can't believe I didn't think of this. This worked great, I called NSNotificattionCenter in my MainViewController which has a function containing a performSegue method. Then in my MenuViewController I Simply set a notification on the case for the respective cell in the didSelectRowAtIndexPath. Thank, this was annoying me no end!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.