Upvote:2

Aprove answer
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    // do stuff

    [tableView deselectRowAtIndexPath:indexPath animated:YES];
}

Upvote:1

func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) 
{
     tableView.deselectRowAtIndexPath(indexPath, animated: true)
}

More Answer related to the Same Query

Upvote:1

   func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
    return UITableViewCell()
}

Credit Goes to: stackoverflow.com

Related question with same questions but different answers