tags:

views:

13

answers:

1

HI In my appliacation I want deletion control button will not work for first row except for all other rows.

Please can anybody tell me how it would be possible.

Thanks

+1  A: 

Implement editingStyleForRowAtIndexPath method in table delegate and return style value depending on cell's index:

- (UITableViewCellEditingStyle)tableView:(UITableView *)tableView
           editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath{
    //Disable editing for 1st row in section
    return (indexPath.row == 0) ? UITableViewCellEditingStyleNone : UITableViewCellEditingStyleDelete;
}
Vladimir