Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

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

Tags:

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 ?

like image 634
Fred Shmed Avatar asked Sep 30 '15 20:09

Fred Shmed


1 Answers

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

Interface Builder Table View Controller

Interface Builder Custom Class

like image 119
Jarrod Smith Avatar answered Oct 07 '22 14:10

Jarrod Smith