Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Sample project about table cell with segue to other view controller

branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

readme.md

u can wire from TableViewController to other view.

ss

For example, at first, you can set TableViewCell as below:

ss

When tap the cell, the view with the number of tapped cell.

ss

To send the number of tapped cell to next ViewController, you can use performSegueWithIdentifier:sender: and prepareForSegue:sender as below.

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    [self performSegueWithIdentifier:@"showDetail" 
                              sender:[NSString stringWithFormat:@"%d", indexPath.row + 1]];
}

- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
{
    DetailViewController *c = segue.destinationViewController;
    c.string = (NSString *)sender;
}
Something went wrong with that request. Please try again.