OK, so I have a UITableView app and on my first page of cells I have 5 of them and when any cell is clicked on it opens up a new page with 3 cells.
Shown here \\//
Code:
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
NSArray* names = nil;
switch ([indexPath row])
{
case 0:
names = [NSArray arrayWithObjects:@"???", @"???", @"???", nil];
break;
case 1:
names = [NSArray arrayWithObjects:@"???", @"???", @"???", nil];
break;
case 2:
names = [NSArray arrayWithObjects:@"???", @"???", @"???", nil];
break;
case 3:
names = [NSArray arrayWithObjects:@"???", @"???", @"???", nil];
break;
case 4:
names = [NSArray arrayWithObjects:@"???", @"???", @"???", nil];
break;
default:
break;
}
if (names)
{
AppTableViewController* ftvc = [AppTableViewControllerAppTableViewControllerWithAppNames:names];
[[self navigationController] pushViewController:ftvc animated:YES];
}
[tableView deselectRowAtIndexPath:indexPath animated:YES];
}
And I would like to have at least one more page of cells when i click one of those 3 cells, But I can't figure out how to do this since the code doesn't specify which page of cells all the cases correspond to.
So My question is in the code how do I make more than two pages of table views in a row?