Reputation: 6394
I have a UITableView which gets loaded with data from a MutableArray. The thing is, within this array I have many different attributes, therefore I would like to enter these attributes into a custom cell programmatically.
Also I would like to include a Slider within the Cell so there will need to be some sort of addition there.
Upvotes: 1
Views: 1758
Reputation: 54425
You say you've looked at tutorials, but have you checked out the "UITableView construction, drawing and management (revisited)" post on http://cocoawithlove.com - this pretty much covers the full custom UITableViewCell gamut, including loading a custom view from a NIB.
Irrespective, one potential approach is to create your own custom cell that expends the UITableViewCell and simply add a UISlider property which you'd then set up within the - (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
method and add it as a sub view via [[self contentView] addSubview:yourUISlider];
, etc.
However, I'd be tempted to have a good look at the http://cocoawithlove.com article, and download the provided project as this will show you the available options in full.
Upvotes: 3