【发布时间】:2011-03-09 15:50:38
【问题描述】:
我正在尝试从 Core Data 加载一个字符串,如果该行中的值等于“--”,附件披露指示器将隐藏并且单元格选择样式应为 SelectionStyleNone。
我试过了,但没有成功
if (entity.value == @"--"){
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
}
或者
NSString *this = entity.value;
if (this == @"--") {
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
cell.selectionStyle = UITableViewCellSelectionStyleNone;
}
两者都不起作用,但这可能吗?谢谢。
【问题讨论】:
标签: iphone uitableview