I have a UIViewController called "Yellow" in my storyboard that I'm adding like this:
_detailVC = [self.storyboard instantiateViewControllerWithIdentifier:@"Yellow"];
_detailVC.location=cell.location;
self.incomingView = _detailVC.view;
[self addChildViewController:_detailVC];
[self.view addSubview:self.incomingView];
self.incomingView.alpha = 0;
[_detailVC didMoveToParentViewController:self];
I need this UIViewController to exist within a UINavigationController as I'm using a push segue and it is giving me the following error:
*** Terminating app due to uncaught exception 'NSGenericException', reason: 'Could not find a navigation controller for segue 'pushDetailVC'. Push segues can only be used when the source controller is managed by an instance of UINavigationController.'
If I go to the view for the "Yellow" view controller, and "embed in Navigation Controller", I still get the same problem.

How would I embed this UIViewController in a UINavigationController so that the push segue works correctly?