【发布时间】:2015-09-10 11:44:27
【问题描述】:
我在 swift 中有一个自定义 Tableview 单元格,并且在该单元格中有一个标签。
我希望能够在您选择单元格时更改标签。
如何在didSelectRowAtIndexPath 中引用我的自定义UITableviewCell 标签
在 Objective C 中,要在 didSelectRowAtIndexPath 中引用我的自定义单元格,我将使用以下内容:
MPSurveyTableViewCell *cell = (MPSurveyTableViewCell *)[tableViewcellForRowAtIndexPath:indexPath];
cell.customLabel.TextColor = [UIColor redColor];
我必须迅速做什么才能达到同样的效果?
【问题讨论】:
标签: ios swift uitableview custom-cell didselectrowatindexpath