I have a tableView that is configured to Push Segue to another view.
The table is devided into 2 sections.
When i push to the next view I allso transfer data and I have a problem with the sections.
Let’s say my section 0 has 2 row and section 1 has 1 row.
How do I check the section 1 rows?
before storybaords and preper for segue I did
row = indexPath.row;
if (section == 0)
{
if (row == 0)
data = @"Zero";
if (row == 1)
data = @"One";
}
if (section == 1)
{
if (row == 0)
data = @"Two";
if (row == 1)
data = @"Three";
}
and now it’s not working. When i click the 0 row in section 1 it put’s “Zero” into data instead of “Two”
Why is that?
How can I effectivly differ between section 0 and section 1?
Dude, where is
section = indexpath.section?and here is a prepareForSegue example;