I have to develop an app with multiple screens. I have automatically generated xib file, but for my other screen I need another xib file. How do I create another xib file?
Input the cocoa touch class name, select it's superclass, and check the Also create XIB file checkbox, select the coding language that you use ( Swift or Objective-C), then click Next button. Select the xib file saved location in the next popup dialog, then click Create button to create them.
(Assuming XCode 4)
In the "File -> New File..." menu dialog, there is a subsection called "User Interface."
You will notice in the description of each of the sub-items, it says "An Interface Builder Document." Those are various types of nibs.
If you're creating a new ViewController
specifically, you can also choose the "Cocoa Touch" section and select the "UIViewController subclass" item. There is a checkbox in the next page called "With XIB for User Interface." which will create the NIB as well as the associated class files.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With