when I selected row, change the backgroundimages?
PhraseSelectedCellViewController *phrView=[[PhraseSelectedCellViewController alloc] initWithFrame:CGRectMake(0, 0, 320, 60)]; [cell.contentView addSubview:phrView]; cell.selectedBackgroundView=phrView; [phrView release]; is ok?
raien
2010-10-29 02:06:38
I done it . thanks
raien
2010-10-29 02:34:23
A:
Hi,
#define kCellHeight 50 //Replace '50' with Height of your UITableViewCell
#define kSelectedCellBackgroundImage @"nameOfYourImage" //replace value inside "" with name of your image
UIImageView *selectedBackgroundView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 320, kCellHeight)];
[selectedBackgroundView setImage:[UIImage imageNamed:kSelectedCellBackgroundImage]];
[cell setSelectedBackgroundView:selectedBackgroundView];
[selectedBackgroundView release];
Sepehr
2010-10-29 03:26:45