首先要明白initWithNibName:是通过指定的.xib文件来实例化对象。而在storyboard 中设计的viewcontroller的访问就不能通过这个方法来实例了,它有专门的方法来实例。在storyboard 中设计的viewcontroller需要通过identifierId 来表明它的身份。在实例这个viewcontroller时也要用到这个identifierid. 伪代码如下UIStoryBoard *storyboard= [UIStorybard storyboardWithName:@"MainStoryboard"bundle:nil];
RushViewController *rushView =[storyboard instantiateViewControllerWithIdentifier:@"RushViewController"];
RushViewController *rushView =[storyboard instantiateViewControllerWithIdentifier:@"RushViewController"];
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货