Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

iOS Build a Self-Destructing Message iPhone App Retrieving and Viewing Data from Parse.com Viewing Images Using UIImageView

Judah Morales
Judah Morales
2,481 Points

Strange touch behavior in tableview

I've made it through the entire tutorial, and everything seems to work as expected except the behavior that occurs when I touch the table cell to view the image or video. I have to select multiple cells in order to view one. It's hard to explain so I made a video to showcase what I was seeing. This happens in the simulator as well as on the phone so I assume it's a code issue that I managed to screw up. Any help is greatly appreciated.

http://youtu.be/s9x3AOKEgjg

2 Answers

Stone Preston
Stone Preston
42,016 Points

looks like you may have implemented didDeselectRowAtIndexPath instead of didSelectRowAtIndexPath. go ahead and go back and double check your tableViewController delegate methods and make sure you implemented

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath

and not

//this is the wrong method
- (void)tableView:(UITableView *)tableView didDeselectRowAtIndexPath:(NSIndexPath *)indexPath
Judah Morales
Judah Morales
2,481 Points

Thanks Stone. Can't believe i overlooked that, lol. Thanks so much for the help! Works great now!

Stone Preston
Stone Preston
42,016 Points

no problem. Ive made the mistake myself a lot. Its easy to do since didDeselectRow comes before didSelect row in the list of suggested methods to auto fill in