Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个带有 3 个按钮的视图和一个包含 3 个视图的标签栏控制器。我正在使用故事板。我想从我的视图转到标签栏控制器的特定视图。例如,我想按下主视图中的第二个按钮,我想直接转到我的标签栏控制器的第二个选项卡。
You can programmatically change tabs by inserting the following into you void/IBAction.
[self.tabBarController setSelectedIndex:1];