I have a delegate for my table view, and would like to be able to trigger an action when the user selects a cell in the tableview.
How is the method – (NSIndexPath *)indexPathForSelectedRow correctly implemented?
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.
If you have the table delegates set up properly (see Apple’s
AdvancedTableViewCellstutorial or any number of good tutorials out there for more info), then you follow Apple’s protocol by implementing this method:Those are just generic examples, but hopefully they shed a little light on the subject for you!