i created tableview in editable mode all tableview rows are contain (-) symbol, but i need some cells are not under editable mode ,if it is possible, Thanks
According to apple documentation of UITableViewDataSource https://developer.apple.com/library/ios/#documentation/UIKit/Reference/UITableViewDataSource_Protocol/Reference/Reference.html
You can use tableView:canEditRowAtIndexPath:
Yes reading the documentation will shed some light on this problem. The method in question that will help you is: tableView:canEditRowAtIndexPath:
This should get you headed in the right direction.
- (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath {
BOOL edit = NO;
if(indexPath.row == 2) {
edit = YES;
}
return edit;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With