我正在使用UITableView
. 在我的表格视图中,我有多个包含多个单元格的部分。我想为每个单元格赋予单元格背景颜色。这意味着each cell should have different colors
。
例如:如果有 20 个单元格意味着每 20 个单元格应该有不同的单元格背景颜色。
您能否告诉我是否可以为每个单元格赋予单元格背景颜色/图像?你能指导我这样做吗?
提前致谢。
编辑
我的 Tableviewcell 颜色如下所示,
First Cell background color : white color
Second Cell background color : red color
Third Cell background color : orange color
Fourth cell background color : gray color
Fifth Cell background color : white color
Sixth cell background color : white color
Seventh cell background color : white color
Eight cell background color : gray color
Ninth cell background color : red color
Tenth cell background color : red color
我想像这样给表格视图单元格背景颜色。然后当 UITableView 重新加载或新打开时,背景颜色会发生变化。你能帮我这样做吗?可以在 iPhone app tableview 中做吗?
提前致谢。