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

  • Home
  • SEARCH
  • 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 8332493
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T02:44:25+00:00 2026-06-09T02:44:25+00:00

I have created an view based app and added two table view controller in

  • 0

I have created an view based app and added two table view controller in that.Here is my flow of events Viewcontroller button is pressed–>Tableview controller loads and if a cell is selected –>second table controller is shown.

here is my code.In Viewcontroller.m

-(IBAction)product:(id)sender
 {
Products *sec=[[Products alloc]init];

UINavigationController *nav = [[UINavigationController alloc] initWithRootViewController:sec];


[self presentModalViewController:nav animated:YES];    
}

In my 1st Tableview controller named as products.m

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
// Navigation logic may go here. Create and push another view controller.

 Description *detailViewController = [[Description alloc] initWithNibName:@"Description" bundle:nil];
 // ...
 // Pass the selected object to the new view controller.
 [self.navigationController pushViewController:detailViewController animated:YES];




 [detailViewController release];

}

My second TableView controller named as description.Now the issue is my second tableview controller not getting displayed and i’m getting issue as

 *** Assertion failure in -[UITableView _createPreparedCellForGlobalRow:withIndexPath:],     /SourceCache/UIKit_Sim/UIKit-1914.84/UITableView.m:6061
 2012-08-03 15:10:51.016 jothi R&D[1112:f803] *** Terminating app due to uncaught  exception 'NSInternalInconsistencyException', reason: 'UITableView dataSource must return a  cell from tableView:cellForRowAtIndexPath:'
*** First throw call stack:
(0x13d3022 0x1564cd6 0x137ba48 0x9b42cb 0xb7d28 0xb83ce 0xa3cbd 0xb26f1 0x5bd21 0x13d4e42  0x1d8b679 0x1d95579 0x1d1a4f7 0x1d1c3f6 0x1d1bad0 0x13a799e 0x133e640 0x130a4c6 0x1309d84  0x1309c9b 0x12bc7d8 0x12bc88a 0x1d626 0x22a2 0x2215 0x1)
terminate called throwing an exception

But if i tried to display Viewcontroller by replacing the description in products.m it works..
Kindly guide me…

  • 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-09T02:44:27+00:00Added an answer on June 9, 2026 at 2:44 am

    Here the solution is In Second Tableview controller add the condition if cell is nil it have to display the table view style.Add the following code in

    cellForRowAtIndexpath

    - (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...
    
    return cell;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created split view based ipad app, where master view is table view
I created a navigation controller based app. The view that opens up below the
I have an iOS app I created as a view-based app in xCode. I
I have app to create a graph i have created a view based app
I wrote simple UINavigationController based app with two ViewControllers; In the first view controller
I've created a table view based on a feed that contains what is essentially
I have created a view for a table as: CREATE VIEW anonymous_table AS SELECT
I have created a view in which there is a capture button. When i
if i have created a view model and have a partial form that is
I have created a street view backbone view. The problem is that when shown,

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.