OGeek|极客世界-中国程序员成长平台

标题: IOS:从辅助 View 中启动导航 Controller [打印本页]

作者: 菜鸟教程小白    时间: 2022-12-13 14:47
标题: IOS:从辅助 View 中启动导航 Controller

在我的应用程序中,我有一个第一个 View Controller ,我以这种方式打开我的第二个 View Controller :

[self presentModalViewController:puntiVendita animated:YES];

但是当我在 secondViewController 中时,我有一个 tableView 并且我想开始一个导航 Controller ......我该怎么做才能通过代码从 seconviewcontroller 启动一个导航 Controller ? 谢谢



Best Answer-推荐答案


只需创建一个导航 Controller :

UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:puntiVendita];
[self presentViewController:navigationController animated:YES completion:nil];

关于IOS:从辅助 View 中启动导航 Controller ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11495064/






欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://sqlite.in/) Powered by Discuz! X3.4