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

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


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

Interface Builder Table View Controller

Interface Builder Custom Class


Try changing your super class to UIViewController or change the controller in your storyboard to TableView Controller

@interface MTViewController : UIViewController, UITableViewDataSource, UITableViewDelegate@end


Drag a new instance of Table View Controller into your storyboard, copy the cells you created in your previous controller into the new one.

This error occurred probably because you used the default UIViewController created by XCode which isn't a UITableViewController.


matomo