关于主界面设置的问题 假如一个应用一进去除了登陆界面就是一个tabbarview,然后tabbarviewcontroller由五个navigationcontroller组成,每个navigationcontroller都能push。我现在要把其中一个navigationcontroller 的 push进去的页面 作为应用一启动就出现的页面,这个要怎么设置。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 启动tabbarController以后,执行[self setSelectedIndex:index];index为目标navigationcontroller的索引 如果是storyboard, 直接把那个剪头指向push后的那个界面就好。也可以在Appdelegate里面, 设置rootVC为那个界面。比如:- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{ self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease]; // Override point for customization after application launch. self.viewController = [[[ViewController alloc] initWithNibName:@"ViewController" bundle:nil] autorelease]; UINavigationController *nav = [[UINavigationController alloc] initWithRootViewController:self.viewController]; self.window.rootViewController = nav; [self.window makeKeyAndVisible]; return YES;} 紧急求救,iPhone apn切换软件 iphone应用的Html5框架哪个最好? iPhone闹钟的问题? client的CFSocket无法使用CFSocket进行读写 急啊!!!关于虚拟机上安装mac os的问题!(小女感激!) ipad开发如何保证各设备全屏显示 跨平台开发 内存问题 ios byte 转nsstring 苹果iOS 多人开发时,多人打包出现证书被撤销的情况 请问一下如何实现在ios的工程里面调用很多单独的c++写的cpp文件里面的函数? 为什么会出现 Undeclared selector iOS 图片列表缩放 uiscrollview 放大 缩小
[self setSelectedIndex:index];
index为目标navigationcontroller的索引
也可以在Appdelegate里面, 设置rootVC为那个界面。
比如:- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
// Override point for customization after application launch.
self.viewController = [[[ViewController alloc] initWithNibName:@"ViewController" bundle:nil] autorelease];
UINavigationController *nav = [[UINavigationController alloc] initWithRootViewController:self.viewController];
self.window.rootViewController = nav;
[self.window makeKeyAndVisible];
return YES;
}