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 8234963
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T18:38:57+00:00 2026-06-07T18:38:57+00:00

The functionality that I am trying to achieve is that first I am showing

  • 0

The functionality that I am trying to achieve is that first I am showing two rows in a UITableView which is showing perfectly. Then on didSelectRowAtIndexpath:, I am adding the numberOfRows in the UITableView, for which I am reloading the UITableView after adding the numberOfRows and the required data.

My problem is that I am passing the new number of rows in the numberOfRowsInSection: (which I have checked, it is passing correctly) but cellForRowAtIndexpath: is called only two times after that, which is the previous numberOfRows value.

My Code:

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    return self.currentSubCategoryRows;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 
   // My code for cell construction goes here
}

-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
   [self.arrWithAdditionalValues addObjectsFromArray:[self.dictSubCategoriesLevel3 objectForKey:[NSString stringWithFormat:@"%d",rowOpened]]];
   self.currentSubCategoryRows += self.arrWithAdditionalValues.count;
            [tableView reloadData];
}

What could be the reason?

Any help would be appreciated!!!

  • 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-07T18:38:59+00:00Added an answer on June 7, 2026 at 6:38 pm

    I found the solution.

    As I was resizing my UITableView as per its number of rows in cellForRowAtIndexPath:, that’s why the next part of the UITableView was not visible, and for the part of the UITableView which is not visible, cellForRowAtIndexPath: is never called.

    Sorry to bother you all.

    Thanks a lot for your help!!!

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

Sidebar

Related Questions

I am trying to achieve a functionality that is able to redirect a user
I am trying to achieve a functionality so that new data appears in new
Basically the functionality that I'm trying to replicate is the @reply system as it
I'm trying to generate the same functionality that www.inkling.com has when you click on
I am trying to add filter functionality that sends a GET request to the
What I am trying to do is create tooltip functionality so that certain words
I'm trying to implement an archive functionality into a webpage that will submit something
I am trying to use some C# code that expands on the GridView functionality
I'm trying to add similar functionality to mobile safari. That is, when a user
I'm trying to implement drag and drop functionality in a Surface Application that is

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.