I thought I figured out myself how to do this question, but it won’t work. The code I used:
-(void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath*)indexPath
{
//timedText = a NSString
[timed replaceObjectAtIndex:1 withObject:timedText];
[SpelerTable reloadData];
}
Can someone tell me what I am doing wrong? Also, I’d like to not use “replaceObjectAtIndex:1” but use the selected cell.
Thanks in advance.
Why index
1and notindexPath.row? Plus you don’t need to reload the whole table; just the row that changed: