Faking a UITableView selection
Posted
by John Smith
on Stack Overflow
See other posts from Stack Overflow
or by John Smith
Published on 2010-04-25T19:35:14Z
Indexed on
2010/04/25
19:43 UTC
Read the original article
Hit count: 232
I have a UITableView where a selection displays some cool stuff in another part of the display. I tried to fake a keypress by writing:
NSIndexPath *ip = [NSIndexPath indexPathForRow: 1 inSection:0];
[tableView selectRowAtIndexPath:ip animated:NO scrollPosition:UITableViewScrollPositionTop ];
[self tableView:tableView didSelectRowAtIndexPath:ip];
However it seems the last line is not being run.
How can I make it run?
© Stack Overflow or respective owner