Tab Bar Application With Navigation Controller

前端 未结 8 912
春和景丽
春和景丽 2020-11-27 10:28

I have a simple iPhone app that has a tab bar and 3 tabs. Each tab loads as a separate nib with a corresponding controller. Each nib contains a tableview with some other con

8条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-11-27 10:41

    The question is too old but SDKs are upgraded and some readers might need new answer. So, now for storyboard users, the answer to use both Tabbar and Navigation controller is pretty simple.

    1. Drag Navigation Controller inside storyboard.
    2. Assign the startup arrow to the new Navigation Controller making the controller as a starting point.
    3. Drag Tabbar controller and set it up with tabs and required controller. You can set up tabbar controller with tabs later also when you wish to do.
    4. Select Navigation controller and bind its 'root viewcontroller' with Tabbar Controller.

    This will load the application with both navigation and tabview controllers.

提交回复
热议问题