Custom table cell background image

I take my first hit in the infrastructure of the iPhone 320, and I can't figure out how to change the background of the table cell to UIImage, and not just the color. Can anyone help me out?

+3
source share
1 answer

You can set backgroundColorcells contentViewwith this way:

cell.contentView.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"image.png"]];

This will work if the cell is a derivative UITableViewCellor three20 TTTableViewCell(since they are derived from UITableViewCell)

+11
source

All Articles