I'm having troubles with my project after upgrading to XCode 7. When I run I get an error, "Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Could not find a storyboard named 'Main' in bundle NSBundle". My storyboard name is Main.storyboard.
If I clean my project it runs just fine. I must clean each time I run or I will get the above error.
If found a number of postings with this same error. The various remedies seem to randomly help some people but not others. So far I have tried the following.
When I load the storyboard manually it crashes with the same messages as autoloading it.
I saved a copy of my working XCode 6 project before the upgrade and after fussing so much with my project I have tried using a fresh copy of the XCode 6 project that was working but this didn't help.
I've seen a number of posts about this problem where the person just gave up and rebuilt their project from scratch. I'm hoping to avoid this.
Can you tried
Select Target - > General -> Deployment info - > Main interface "Choose your Storyboard name"
May this help you
Try this,
Please Check Target Membership in your file inspector.
Its working for me.
If you use the same code as follow
UIStoryboard *mainStoryboard = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
then just change [NSBundle mainBundle]
to nil and my problems with simulator reinstalls are disappeared.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.