iPhone app crashes when I change "Main Interface"
I have a navigation based iPhone app, and I want to load a view (MainMenu.xib) when the app is launched, instead of MainWindow.xib. If I change 开发者_如何学Cthe target's "Main Interface", the app crashes when it is launched. How do I fix this?
You have to add the view you want to display on MainWindow.xib......in the IB of MainWindow.xib you have to change the name of the class as well as the nib name (give the name of the class)
After doing this make the object of the view in the Application delegate
In navigation based you also need to give the name of the class you want to display(this class is the class in which you had designed your table view)
adding this comment a few years after the problem first posted as can cause problems if you have Storyboards to manually change MAIN INTERFACE instead of choosing from drop down. If value in field is not a .storyboard file then xocde changes the plist setting to NIB based project and breaks the whole project.
See my comment here
What does "Main Interface" in Xcode actually *do*?
精彩评论