Storyboard "Main", but didn't get a UITableView when using UITableViewController

Fred Shmed picture Fred Shmed · Sep 30, 2015 · Viewed 32.4k times · Source

I have been going through this tutorial, "Option 2: Prototype Cells" I implimented all the steps, but, the following code gives me an error:

@interface MTViewController : UITableViewController

@end

the error message is:

instantiated view controller with identifier "UIViewController-BYZ-38-t0r" from storyboard "Main", but didn't get a UITableView.'

Here is what I tried - I changed UITableViewController to UIViewController and the error went away. But, the tableview remains blank. Can you tell me why this is ?

Answer

Jarrod Smith picture Jarrod Smith · Mar 21, 2016

In your storyboard, you need to make the root view of your UITableViewController a UITableView.

Interface Builder Table View Controller

Interface Builder Custom Class