iOS 不同tabbar之间的页面跳转

//先pop自己
[self.navigationController popViewControllerAnimated:YES];
//获取tabbar 
CYXBaseTabBarController *tabBar = (CYXBaseTabBarController *)kApplication.delegate.window.rootViewController;
//先切换到要跳转的对应的tabbar标签
tabBar.selectedIndex = 1;
//获取NavigationController数组
NSArray *views = tabBar.viewControllers;
UINavigationController *navi = (UINavigationController *)views[1];
CYXMyListViewController *myListVc = (CYXMyListViewController *)[navi.viewControllers objectAtIndex:0];
CYXMyOrderViewController *myOrderVc = [[CYXMyOrderViewController alloc] init];
[myOrderVc setHidesBottomBarWhenPushed:YES];
[myListVc.navigationController pushViewController:myOrderVc animated:NO];
                      

你可能感兴趣的:(iOS 不同tabbar之间的页面跳转)