//button to display content
-(ns string *)table view:(UITableView *)table view titlefordeleteconfirmationbuttonforrowatdinexpath:(NSIndexPath *)index path {
Return @ "Delete";
}
//Here's how to click Delete.
-(void)table view:(UITableView *)table view commitEditingStyle:(UITableViewCellEditingStyle)editing style for rowatindexpath:(NSIndexPath *)indexPath {
}
1. If your data is obtained from the server, call the interface directly and get the data source again.
[table view reload data]; That's enough
2. If you only want to modify local data.
[_ data removeObjectAtIndex:[index path row]]; //Delete the data in the _data array
[table view deleteRowsAtIndexPaths:[NSMutableArray array with object:index path]with row animation:uitableviewroanimationautomatic]; //Delete the cell of corresponding data.