Use UITableviewDelegate
method willDisplayCell: forRowAtIndexPath:
and check indexPath.row
with dataSource
array then fire the method.
- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath {
if ([dataSourceArray count]/2 == indexPath.row) {
//invoke the method here
}
}