I have a segmented control in the header of a navigation controller, I want to add an object to a table view controller thats also in this navigation controller.
He
You make what I call "generic" segues that are not associated with an action/trigger. See my answer here: How to make and use generic segue
Make 2 of these segues, then in your IBAction method for your segmentedControl call performSegueWithIdentifier:. For example:
- (IBAction)segmentCtrlChanged:(id)sender {
UISegmentedControl *seg = sender;
if (seg.selectedSegmentIndex == 0)
[self performSegueWithIdentifier:@"segue1" sender:self];
else if (seg.selectedSegmentIndex == 1)
[self performSegueWithIdentifier:@"segue2" sender:self];
}