Question

I could have sworn this was a new feature in iOS 5, but I have been looking all over the place and not finding anything. Isn't there a more native approach to selecting multiple rows now?

Thanks!

Was it helpful?

Solution

Assuming your instantiated tableview has the usual name of tableView:

[tableView setAllowsMultipleSelection:YES];
[tableView setAllowsMultipleSelectionDuringEditing:YES];

Will allow you to select more than one row.

You can read the index paths of your selected rows thusly:

NSArray *paths = [tableView indexPathsForSelectedRows];

Documentation:

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top