Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I am trying to create a new app with Singe View template but there is no xib or storyboard option to make my interface as xib file !!! why does Apple remove xib from iOS 7 ?!! How can I create application with xib interface files ?

enter image description here

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
559 views
Welcome To Ask or Share your Answers For Others

1 Answer

  • Create a new project
  • Select Single View Application
  • Set ProjectName and other settings
  • Save Project at location
  • Select Project in Navigator Panel in Left
  • Remove Main.storyboard file from project
  • Add New .xib file in Project
  • Set Main Interface to your .xib file in "General Tab" on right panel.
  • Paste following code in didFinishLaunchingWithOptions method
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.rootViewController = [[UIViewController alloc] initWithNibName:@"YourViewController" bundle:nil];
[self.window makeKeyAndVisible];

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...