I want to set a different image for each cell of my table view. I don’t know how to do this — please help me.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can create a custom cell with a UIImageView in it, but the simplest way is to set the built in image view of the default UITableViewCell in your -cellForRowAtIndexPath table view delegate. Something like this:
Where image is a UIImage that you created by loading from a URL or from the local application bundle.