更新xcode,报错* Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit_Sim/UIKit-3505.16/UIApplication.m:3294
在Info.plist中,可以找到:“Main storyboard file base name” String “Main”,删掉这个条目, 再启动,屏幕变成了黑屏
手动添加window
- (BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary )launchOptions {
// Override point for customization after application launch.
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; //全屏window
self.window.backgroundColor = [UIColor whiteColor]; //白色背景
[self.window makeKeyAndVisible]; //
return YES;
}
ok,这个由于更新xcode7报错已解决!
如果按照上面修改完,发现还在报错,那么去看看你的项目是不是加了引导页
把上面的add方法,变成下面的就好。
这个add方法在xcode7之前是没有问题的,在xcode7后不能这样写了!
下面分享一个ios9适配的文章,很实用
https://github.com/ChenYilong/iOS9AdaptationTips
----iOS研究院 qq群:305044955