First off, please don't discredit code written years ago. It still works, the only code that should be reworked are big blobs of code that are basically hacks to get features that weren't available in the SDK but are now. To accomplish your idea, you'll need to create an array called indexPathsOfSelectedRows. When a user touches a row, check whether the amount of objects in the array is greater than your maximum. If so, delete the object at index 0. Then, add the indexpath of the row that user just touched. Then reload your tableview.
In the cellForRowAtIndexPath, you'll want to check whether your array contains the indexPath. If so, give it a checkmark, if not, don't.
__________________
If you are looking for a quality developer, I'm your man. Give me a PM if you are interested.
New app - See screenshots and details at www.globaclock.com.
If you want to thank me, click the link. Every click counts. If you want to do more, buy my app. A link is available on my website. Thanks.
Last edited by Domele; 01-12-2012 at 05:47 PM.
|