2013-02-12 71 views
0

我有兩個故事板名爲HomeView~iphone.storyboardHomeView~ipad.storyboard。這兩個故事板在故事板文件中都有一個initialViewController故事板設備特定的資源

UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"HomeView" 
                bundle:nil]; 
UIViewController *controller = [storyboard instantiateInitialViewController]; 

當我嘗試訪問instantiateInitialViewController時出現以下錯誤。

找不到捆綁NSBundle - NSInvalidArgumentException

命名爲HomeView你有什麼想法故事板?蘋果documentation表示〜iphone和〜ipad支持該軟件包中的任何文件。

+0

你有沒有嘗試過任何步驟從這[先前所以後](http://stackoverflow.com/questions/11531955/xcode-deployment-error-nsinvalidargumentexception-could-not-find-a-storyboar)?錯誤消息是相似的。 – 2013-02-12 14:55:51

回答

2

您是否嘗試過在iPhone上使用HomeView.storyboard而在iPad上使用HomeView~ipad.storyboard