Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8300295
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T16:30:55+00:00 2026-06-08T16:30:55+00:00

I have a uitableview with 50 rows populated from a predefined nsarray. How can

  • 0

I have a uitableview with 50 rows populated from a predefined nsarray.

How can I select multiple the rows with say maximum 3 allowed at a time and show check when selected and remove check when deselected/

I am really new to xcode and any help is much appreciated. Thank you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T16:30:56+00:00Added an answer on June 8, 2026 at 4:30 pm

    Your data needs to keep track of whether it is selected or not.

    Two common ways are: each object in your predefined array has a BOOL that indicates whether or not it is selected, or you keep a second array that holds only references to selected objects. Since you’re limited to three selected, the second option might be better.

    When someone selects a cell in your table, you change the selection status of the related object, either switching its BOOL or adding/removing it in the extra array. This is also the place to check whether you already have as many selections as you allow. If selections have changed, you then tell your table to reload data.

    In cellForRowAtIndexPath: you check whether or not the object is selected and mark it accordingly.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a UITableView with 3 empty rows. The user can select which text
I have a uitableview that is populated from a sqlite query. I want to
I have a UITableView with rows that each have two actions that can be
I am stuck in a problem, I have a uitableview with rows let say
I have a UITableView populated with 27 rows. I am trying to change the
I have a UITableView with draggable rows and I can add/remove items. The datasource
I have UITableView with images as rows (cells). I use EGOImageView to load images
I have a UITableView which is configured to allow rows to be moved between
So I have a nicely working UITableView consisting of 3 rows (each including and
I have a UITableView on a UIViewController. And this table has say 5 visible

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.