So I have a UIViewController class called SocialMainViewController. It has an instance of a TwitterViewController (which inherits from an UITableViewController) and an instance of a FacebookViewController (which also inherits from an UITableViewController).
@interface SocialMainViewController ()
@property (strong, nonatomic) TwitterViewController* twitterVC;
@property (strong, nonatomic) FacebookViewController* facebookVC;
...
@end
@implementation SocialMainViewController
@synthesize twitterVC = _twitterVC;
@synthesize facebookVC = _facebookVC;
..
- (void)viewDidLoad
{
[super viewDidLoad];
UIColor* color = [[UIColor alloc] initWithRed:0.2 green:0.2 blue:0.2 alpha:1.0];
[self.navigationController.navigationBar setTintColor:color];
// Do any additional setup after loading the view
self.facebookVC = [[FacebookViewController alloc] init];
self.facebookVC.view.frame = self.view.bounds;
[self.view addSubview:self.facebookVC.view];
}
So the Facebook view controller gets all the information from facebook and store it in an array. But the cellForRowAtIndexPath on that FacebookViewController class never gets called and hence only an empty table view is visible.
I'm actually trying to switch between the facebookviewcontroller and twitterviewcontroller tableviews. That is why I had the two inside the socialmainviewcontroller.