Reputation: 1
Forgive the Beginner question, but I copied and pasted from the apple developer site, changed the names, and it gives me a parse error. Here is my code:
- (IBAction)unwindToList:(UIStoryboardSegue *)segue {
AddgameViewController *source = [segue sourceViewController]
gametem *item = source.gameitem
if (item != nil) {
[self.gameitems addObject:item];
[self.tableView reloadData];
}
}
What am I doing wrong? When I add a semicolon after segue like it asks me to, I get that parse error.
Upvotes: 0
Views: 566
Reputation: 9038
Try this: (added two semicolons and changed gametem to gameitem)
- (IBAction)unwindToList:(UIStoryboardSegue *)segue {
AddgameViewController *source = [segue sourceViewController];
gameitem *item = source.gameitem;
if (item != nil) {
[self.gameitems addObject:item];
[self.tableView reloadData];
}
}
Upvotes: 4