0

I currently have 3 tabs connected to a common UITabBarController. When one of the tabs is selected the user is taken to a UITableView with 3 cells which can be selected. When a cell is selected the user is taken to a new page with a UINavigationBar at the top. My understanding is that the UINavigationBar is supposed to include some sort of back button and I couldn't figure out how to enable it.

In place of the default back button, I dragged a UIButton to the corner and connected it to the 'Show Detail' property of the previous view but when I press the UIButton I am taken to the right UITableView but the tabs are missing for navigation. What am I doing wrong? My segues look like this:

enter image description here

smottt
  • 3,272
  • 11
  • 37
  • 44
user3185748
  • 2,478
  • 8
  • 27
  • 43

1 Answers1

1

The UINavigationController has the back functionality. How to go back one view in UINavigationController?.

Here is some old tutorial on how to combine that with a tabbarcontroller. should still be the same principles.

Community
  • 1
  • 1
David Karlsson
  • 9,396
  • 9
  • 58
  • 103
  • So is that functionality only available for a UINavigationController? Because when I go to drag one onto my storyboard they come as two views. I only need the second one since I already had my UITableView complete before starting the detailed view and thus I just have a UIViewController with a UINavigationBar on top. – user3185748 Jan 05 '15 at 00:39
  • Well you can always be creative and implement [popping](http://stackoverflow.com/questions/14907518/modal-view-controllers-how-to-display-and-dismiss) of the views yourself, maybe [unwinding](http://stackoverflow.com/questions/12561735/what-are-unwind-segues-for-and-how-do-you-use-them) is what you want to do – David Karlsson Jan 05 '15 at 00:42
  • It turns out the segue unwinding was just what I needed. Thank you for pointing me in the right direction! Have a great evening – user3185748 Jan 05 '15 at 00:49