I am displaying a list of users and their respective badges they have won, so each user has three different counts (gold, silver, bronze). In addition to displaying the # of badges they've earned, I want to have a rectangle in the background that is resized depending on how many badges they have (kind of like a bar chart).
This is how I am attempting to do it so far. (I have a UIView called goldRect in my storyboard, with a height of 20 and width of only 1 pixel to start.) Then I do:
cell.goldRect.frame = CGRectMake(cell.goldRect.frame.origin.x, cell.goldRect.frame.origin.y, 28*numGolds, cell.goldRect.frame.size.height);
But nothing changes, the bar still remains at width one pixel. Any help?