【发布时间】:2011-03-25 14:47:25
【问题描述】:
我有一个带有 4 个选项卡的 tabBarController。在第一个中,我需要显示一个 UINavigationController ,其中有一个 UIView 。当用户在该视图中按下按钮时,我需要在选项卡 1 中显示另一个 UINavigationController 来替换旧的。这可能吗? 我尝试使用此代码没有运气
UINavigationController *tableNavController = [[UINavigationController alloc] initWithNibName:@"Nav2" bundle:nil];
[[self.tabBarController selectedViewController] setView:tableNavController.view];
这会替换视图,但不会替换控制器。 请帮忙。 提前致谢。
【问题讨论】:
标签: iphone objective-c uinavigationcontroller uitabbarcontroller