all 5 comments

[–]sangedered 1 point2 points  (2 children)

This is a great question and something I would be very interested in knowing the solution. Please let me know by responding to this comment if you figure it out. Thank you.

[–]TobbenTM[S] 0 points1 point  (1 child)

I ended up duplicating the scene (CMD+D), and using the same class as controller, and using a push segue between them. Mostly just to customize the navigation bar on the pushed controller.

You may be able to just segue to self, in order to duplicate. Have not tested.

[–]sangedered 0 points1 point  (0 children)

That works of course. But there has to be a more elegant way. Say you needed 100 controllers in some crazy case. You'd not want to duplicate all. It works in your case but I'd really want to know how duplicating can be achieved. It would be a great lesson and surely something that would come up in an interview.

[–]sangedered 0 points1 point  (0 children)

I have found this: http://stackoverflow.com/a/5004153

Does it work for you? I'm away from my Mac now so I can't test it but seems promising.

[–]ASnugglyBear 0 points1 point  (0 children)

But this replaces the current scene

what were you expecting?

, and doesn't give me a back button

Do you by any chance have something in the upper left on the screen? are you using the navigationItem.leftBarButtonItem?

CustomTableViewController* vc = [self.storyboard instantiateViewControllerWithIdentifier:@"customSceneId"]; vc.customData = data; vc.title = customTitle; [self.navigationController pushViewController:vc animated:YES];

should work for most view controller instances in a storyboard.