mano
mano

Reputation: 3

Selecting a row in uitableviewcell

how to make a row in uitableview back to white after selecting.

My problem is when I select a row in uitableview it shows me blue color and it remains on. It doesn't go off, I mean back to white color.

How to do that. any help please..

Upvotes: 0

Views: 83

Answers (1)

Jacob Relkin
Jacob Relkin

Reputation: 163228

Conform your class to the UITableViewDelegate protocol and define a delegate method like this:

-(void)tableView:(UITableView *) tableView didSelectRowAtIndexPath:(NSIndexPath*) indexPath {
    [tableView deselectRowAtIndexPath:indexPath];
}

Upvotes: 1

Related Questions