I'm creating the TableViewController programmatically (not using a xib or storyboard) in a ViewController (handling several view and view controllers), like this:
- (void)viewDidLoad
{
[super viewDidLoad];
tableViewController = [[UITableViewController alloc]initWithStyle:UITableViewStylePlain];
[self.view addSubview:tableViewController.tableView];
}
When running, the program halts with the error:
Assertion failure in -[UITableView dequeueReusableCellWithIdentifier:forIndexPath:], /SourceCache/UIKit_Sim/UIKit-2372/UITableView.m:4460 Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'unable to dequeue a cell with identifier Cell - must register a nib or a class for the identifier or connect a prototype cell in a storyboard'
Debugging reveals that the tableView is blank when added to self.view.
Do I need to do some extra, manual initialization for the tableView, normally being found in a nib file?