I’m having trouble connecting a TableView (I think this is my error, maybe is another one), I have this error:
-[NSObject tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x796aaa0
This is a problem connecting, isn’t it?
This is my notice.h:
#import <UIKit/UIKit.h>
@interface Notice : UIViewController <UITableViewDataSource, UITableViewDelegate>
{
UITableView *mainTableView;
NSMutableArray *contentsList;
}
@property (nonatomic, retain) NSMutableArray *contentsList;
@property (nonatomic, retain) IBOutlet UITableView *mainTableView;
@end
in notice.m, I have the usual methods for UITableView implementation.
this is my interface builder:




Thank you in advance
You’ve connected your table’s data source outlet to ‘First Responder’ when in fact you should connect it to your view controller. They’re not the same thing. The First Responder icon is a proxy for the “first responder”, i.e. the current first object in the responder chain. It changes depending on the state of your program, and it’s not likely to point to your view controller.