Note that there are some explanatory texts on larger screens.

plurals
  1. POUITableView does not show any cells after UIViewController popped then returned to
    primarykey
    data
    text
    <p>I have a UITableView within a UIViewController and am having an issue where the table displays ok on first load via a segue, but when you push the back button on the header, then go forward to the UIViewController again the table is blank.</p> <p>I'm using a custom classed tableview, but the default methods like numberOfRowsInSection and cellForRowAtIndexPath are being called on the second load. In fact, the cellForRowAtIndexPath method is returning a cell with the cell.textlabel.text properly set as expected. numberOfRowsInSection is returning the correct number of rows. And numberOfSectionsInTableView is returning 1. But when everything finishes loading there's nothing in the table.</p> <p>I'm using storyboards and the prototype cell is set up with a reuse identifier. I've tried calling [tableView reloadData] from the view controller in both the viewDidLoad and viewWillAppear methods.</p> <p>The datasource and delegate are both set ok (I think - or else it wouldn't work first time it's loaded).</p> <p>I'm not doing anything different (that I can see) to other tables in my app, apart from using the UITableView within a UIViewController rather than using a UITableViewController. Is there anything that I'm missing that the UITableViewController handles automatically?</p> <p>I'm a bit stumped - any ideas would be much appreciated! </p> <p>EDIT: The custom class used in the UITableView isn't under ARC control, as it's an old library that I'm using. I'm using the -fno-objc-arc flag. Could this be something to do with it? </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload