Delete a table's row


/ Published in: Objective C
Save to your folder(s)

Just add this delegate method to enable the row delete.


Copy this code and paste it in your HTML
  1. - (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath
  2. {
  3. [self.tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:UITableViewRowAnimationFade];
  4.  
  5. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.