I'm trying to add a ViewController to my TableView cell however it is not showing up when testing.
PhotoLocation is a UIViewController subclass. I have a View Controller created on the StoryBoard with a bunch of UILabels, UITextFields, UISwitch, etc configured on it. PhotoLocation is associated with that StoryBoard View Controller and its Identifier is PhotoLocation.
In a separate controller - UITableViewController, I have a working TableView with cells that are populating with various information, I am trying to add the PhotoLocation VC as a subview of each cell. (Note: PhotoLocation is a freeform sized VC that is of size 210x100).
In my cellForRowAtIndexPath
method I'm doing the following:
// snip code above which sets up the cell and performs various other things
PhotoLocation *photoLocation_ = [self.storyboard instantiateViewControllerWithIdentifier:@"PhotoLocation"];
[photoLocation_.view setFrame:CGRectMake(115, 0, 210, 109)];
[cell.contentView addSubview:photoLocation_.view];
return cell;
When I run the app the subview does not show up in the cells. Is there something here I'm missing?