I have an UITabView iPad app, using XCode 4.5, Storyboards and iOS 6. I have a UIView scene, with two UITableViews (one in the upper left quadrant, the other at the bottom half of the UIVIew). My problem is that I need to identify which UITableView is being referenced for numberOfRowsInSection and also cellForRowAtIndexPath. I have given both UITableViews names:

I don’t think this is correct because when I but a breakpoint on the numberOfRowsInSection it arbitrarily selects the lower UITableView (previousAppointments), never selecting the upper UITableView (clientList). Code is follows:
//------------------------------------------------
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
if (tableView == clientList) {
int y = listOfClients.count;
return 1; // return list of clients <--------- TODO
}
else if(tableView == previousAppointments) {
return 2; // return number of appointments for this client <------------ TODO
}
return 1;
}
I need to be able to identify which UITableView is selected so I can populate it with the correct data.
What am I doing wrong?
You should set up IBOutlets to each table view, and use that outlet name in the if statement