So I was recently doing chapter 6 and I got a little confused on page 127 when it tells you to load the NIB file. It asks you to use the following code.
[code]NSBundle *appBunle = [NSBundle mainBundle];
// Look in the appBundle for the file BNRReminderViewController.xib
BNRReminderViewController *rvc = [[BNRReminderViewController alloc]initWithNibName:@“BNRReminderViewController” bundle];
The reason I am confused is because I have no idea why we even have to load the NIB file. If I connect the .XIB File to the File’s Owner, set the view outlet, and make the connections like it asks you to on pages 128 - 130, and change the code to the following, it still works perfectly fine. The project compiles and runs without any errors
BNRReminderViewController *rvc = [[BNRReminderViewController alloc]init];
Could someone please help me understand this? Thanks in advance