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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T05:20:59+00:00 2026-05-27T05:20:59+00:00

I have a view that adds another view on top in this manner: –

  • 0

I have a view that adds another view on top in this manner:

- (void)showAreaEditView {

    NSLog(@"SHOWING AREA EDITOR VIEW");

    if (self.thisAreaEditorView == nil) {

        // Create View
        AreaEditorView *tmpViewController = [[AreaEditorView alloc] initWithNibName:@"AreaEditorView" bundle:nil];
        self.thisAreaEditorView = tmpViewController;
        [tmpViewController release];

        // Hide the back button
        self.thisAreaEditorView.navigationItem.hidesBackButton = YES;

    }

    self.thisAreaEditorView.myInspectionID = self.myInspectionID;
    self.thisAreaEditorView.loggedIn = loggedIn;
    self.thisAreaEditorView.loggedInGroup = loggedInGroup;

    // Slide view up

    [self.view addSubview:thisAreaEditorView.view];


    CGRect endFrame = CGRectMake(self.view.frame.size.width/2 - thisAreaEditorView.view.frame.size.width/2,
                                 self.view.frame.size.height/2 - thisAreaEditorView.view.frame.size.height/2, 
                                 thisAreaEditorView.view.frame.size.width, 
                                 thisAreaEditorView.view.frame.size.height);

    CGRect startFrame = endFrame; // offscreen source

    // new view starts off bottom of screen
    startFrame.origin.y += self.view.frame.size.height;
    self.thisAreaEditorView.view.frame = startFrame;

    // start the slide up animation
    [UIView beginAnimations:nil context:NULL];
    [UIView setAnimationDuration:.6];   
    thisAreaEditorView.view.frame = endFrame; // slide in
    [UIView commitAnimations];

}

I’m sure you can just ignore the slide part, I feel the addSubview is relevant.

Then in thisAreaEditor I have the view with the table and buttons and such. UITableView delegate/datasource is going to File’s Owner as normal.

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {

    NSLog(@"numberOfRowsInSection returning %d", [tableData count]);
    [tableData count];

}

This function numberOfRowsInSection returns 4

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {

    static NSString *CellIdentifier = @"Cell";

    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
    if (cell == nil) {
        cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
    }

    // Configure the cell...
    NSString *thisText =  [tableData objectAtIndex:indexPath.row];
    cell.textLabel.text = thisText;

    NSLog(@"looking at cell %d text:%@", indexPath.row, thisText);

    return cell;

}

But cellForRowAtIndexPath never gets called.

I’m at a loss here, I have no idea how it can seem to work fine but one of the delegate functions simply not be called.

I have tried [bigTable reloadData] and so on, the table just never gets populated and no logs from the function output.

Thanks in advance.

  • 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-05-27T05:21:00+00:00Added an answer on May 27, 2026 at 5:21 am

    You might have just edited this out, if so I’m sorry, but it looks like you forgot to return tableData’s count.

    - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
        NSLog(@"numberOfRowsInSection returning %d", [tableData count]);
        return [tableData count];
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a button that, when tapped, adds a label inside a view. Anytime
I have an app using a UITabBarController, and I have another view that needs
I have a button that adds a new row to the view with the
I have a view that has a list of jobs in it, with data
I have a view that I want to add some custom drawing to. I
I have a View that can vary significantly, depending on the 'mode' a particular
I have a view that is joining two tables and ordering by the first
I have a view that is loaded in the MainWindow.xib. It is just a
I have a view that takes data from my site and then makes it
I have a view that I want to be converted into JSON. What 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.