is it possible to implement a subview (like an image) at only one row of a UITableViewCell? I’m having an extra class for my Cell. At the moment I call the function with [tblcell addimage]; but it only adds the image at the last cell. Is it possible to add the image at indexPath.row? If yes, how? (I know, that I need to do: [tblcell addimageatIndex:indexPath.row];, that’s not the problem, how can I insert the subview at indexPath.row?)
If it helps: I have a nib for the cell.
Thanks for answers!
You can do something like this:
Basically you are adding an
UIImageViewinto yourcell.contentView.Depending on the case, its nice to create a custom UITableViewCell, if you think its simpler than adding UIViews to your normal (
UITableViewCell*) cell. But in your case, you say:Only one. So I ask you, is it worth to edit your custom cell just for one? Well, its up to you, but I would probably just add the subView I want into the contentView.