“setText:已弃用”警告

时间:2011-06-07 19:35:56

标签: objective-c ios compiler-warnings

当我运行我的应用程序时,弹出一个警告“'setText:'已被弃用。我可以重写这行代码来摆脱错误吗?

cell.text = [moreArray objectAtIndex:row];

由于

1 个答案:

答案 0 :(得分:7)

使用此:

cell.textLabel.text = [moreArray objectAtIndex:row];