navigationcontroller返回上部navigationcontroller

时间:2015-06-07 10:25:38

标签: ios uinavigationcontroller

问题显示在图片中。如何从viewcontroller C返回到A. 方法popViewControllerAnimated不起作用。

enter image description here

1 个答案:

答案 0 :(得分:2)

您的控制器层次结构中存在问题。您的UINavigationController A和C之间不应该有UIViewController

由于UITabBarController推动嵌入UINavigationController的控制器A,您的导航功能已经为此标签设置,稍后无需再刷新另一个。

因此,要解决您的问题,您应该在第一个选项卡中使用它:UITabBarViewController - > UINavigationController - > UIViewController A - > UIViewController C.这样,popViewControllerAnimated就可以了。