I am trying to embed a UITableView into my ViewController's main UIView that is 75% the width of the screen. Ideally this UITableView would also be embedded into a Navigation Controller. Also, it seems I cannot use UIContainerViews with iOS 5 because I encounter the error "Could not instantiate class named UIStoryboardEmbedSegueTemplate" (cf. NSInvalidUnarchiveOperationException with ContainerView).
To do this, I have created a UIView within my ViewController's main UIView that is 75% the width of the screen. Within that UIView I have placed a UINavigationBar and a UITableView. I instantiate the UITableViewController in the ViewController's - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
function. Once instantiated, I connect my ViewController's UITableView to the UITableViewController's UITableView via self.tableViewController.tableView = self.tableView
.
Everything seems to work alright, except that my UITableView isn't showing any cells, even if I preload it with data.
What additional data may I provide to help diagnose the problem? I of course don't receive any error message, and the datasource does indeed receive the data and I call [self.tableView reloadData]
after the datasource is updated.
UPDATE 1
Ultimately this is the kind of behavior I would like, except that instead of multiple web views I would like multiple table views each embedded in its own navigation controller. I'm guessing that Chrome for iOS just takes a screenshot (?) of the webpage since interaction is not enabled when scrolling through tabs, but how would you do this if you wanted to preserve interaction?
UPDATE 2
The particular line seems to be CustomCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]
where static NSString *CellIdentifier = @"New Cell"
(and the appropriate prototype UITableViewCell is defined such in IB). However, the code doesn't seem to crash on this line; instead, a breakpoint seems to be initiated (Thread 1: Breakpoint 1.1
) that I did not designate. In addition, this only happens when testing on my iOS device. Everything works fine when testing via the iOS simulator.