我試圖加載從核心數據的數據(串),如果該行該值等於「 - 」將隨機指標披露將隱藏和SelectionStyleNone。隱藏/顯示UITableViewCell的附件披露指標
我嘗試這樣做,但沒有成功
if (entity.value == @"--"){
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
}
或者
NSString *this = entity.value;
if (this == @"--") {
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
cell.selectionStyle = UITableViewCellSelectionStyleNone;
}
兩個不工作...但是這是可能的,但?感謝
...因爲==比較指針 –
完美的作品,非常感謝你=) –