I\'m working on a simple iPhone app.
I have 1 UINavigationController and 2 subclasses of UIViewController.
I have a MainWindow.xib file, a PersonListView.xib
Changing the name of the xib has absolutely no effect on the contents of that xib. You have to change the class name in the Info panel if you want to change what subclass you're using.
From the exception it appears that the binding was not done properly. The method signature does not seem to be right judging by the exception. Is the button action linked to a method with return type IBAction? The signature of the method should be
-(IBAction) methodName;
I think you are using a tab bar, correct?
If so, think about it this way. Each tab defined in the MainWindow xib must be defined as the custom view controller type, because that is the type that the tab bar will create when it is loaded. The tab bar creates view controllers for each tab defined when it is loaded.
It's not enough to create an instance of just any view controller and then load your custom NIB (which is what the tab bar you have defined is doing right now), because the wiring in your custom view will have nothing to attach to.
Thus, make sure each view controller defined under each tab in MainWindow.xib (use the tree view in IB to examine this) is set to the right custom UIViewController type in addition to pointing at your custom XIB which must ALSO have the file's owner set to the correct type (though that's only important if you are wiring anything to Files Owner beyond the basic view).
I got the same mistake.
The problem is, that you didn't set the target of PersonListViewController.m.
Go to info of PersonListViewController.m, select targets section and make sure that the target of your app is checked.