I was experimenting with static cells, therefore I made a Table View and embedded a UITableViewController
in it and then added some static cells. Everything worked fine until I made a new UITableViewController
class and connected it as a custom class thorugh the interface builder. Since then, when I build the App, it just shows an empty Tableview without any cells in it and now I'm wondering what I'm missing.
I tried some researching, I doubt I'll be the first one to ask, but evidently I must have been looking for the wrong thing. I guess there must be something that goes to ViewDidLoad
, so the static cells get loaded?
Here is the solution:
Remove the following methods from the .m file:
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
}
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
}
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With