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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T06:56:23+00:00 2026-05-26T06:56:23+00:00

The following code: listViewPopoverControllerOL = [[UIPopoverController alloc] initWithContentViewController:myBranchesListViewPage]; produces the following crash in iPad2

  • 0

The following code:

listViewPopoverControllerOL = [[UIPopoverController alloc] initWithContentViewController:myBranchesListViewPage];

produces the following crash in iPad2 with iOS5. As a comment I have to notice that the same code works perfectly in iOS4.3.

*** Terminating app due to uncaught exception 'NSGenericException', reason: 'The content view controller argument must be the root of its associated view controller hierarchy.'
*** First throw call stack:(0x370cb8bf 0x35eaa1e5 0x370cb7b9 0x370cb7db 0x306f378d 0x306f0db9 0x5692d 0x567d1 0x37025435 0x303499eb 0x303499a7 0x30349985 0x303496f5 0x3034a02d 0x3034850f 0x30347f01 0x3032e4ed 0x3032dd2d 0x35bdfe13 0x3709f553 0x3709f4f5 0x3709e343 0x370214dd 0x370213a5 0x35bdefed 0x3035c743 0x2871 0x2830) terminate called throwing an exception

Where “myBranchesListViewPage” is defined as:

MyBranchesListView_iPad* myBranchesListViewPage

and “MyBranchesListViewPage” is defined as:

MyBranchesListView_iPad : UIViewController<UITableViewDelegate, UITableViewDataSource, MyDetailParserDelegate, UISplitViewControllerDelegate>

I have no idea why I have this problem in iOS5 (Xcode 4.2) but not with iOS4.3 (Xcode 4.1)

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-26T06:56:24+00:00Added an answer on May 26, 2026 at 6:56 am

    I had this same issue. In my case I was doing the following:

    MyViewController * popupController = [[MyViewController alloc] initWithNibName:@"MyViewController" bundle:nil];
    [popupController setDelegate:self];
    UINavigationController *  navigationController = [[UINavigationController alloc] initWithRootViewController:popupController];
    [navigationController setNavigationBarHidden:YES animated:NO ]; 
    
    UIPopoverController* aPopover = [[UIPopoverController alloc]
                            initWithContentViewController:popupController];
    [popupController release];
    
    [navigationController release];
    

    To solve this, I just changed to pass in the navigationController to init on UIPopoverController instead of the popupController:

    UIPopoverController* aPopover = [[UIPopoverController alloc]
                    initWithContentViewController:navigationController];
    

    Not adding a navigation controller to the popupController at all also fixed it, but then you obviously don’t have a navigation controller in the popup.

    MyViewController * popupController = [[MyViewController alloc] initWithNibName:@"MyViewController" bundle:nil];
    [popupController setDelegate:self];
    UIPopoverController* aPopover = [[UIPopoverController alloc]
                    initWithContentViewController:popupController];
    [popupController release];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Following code will compile but crash at run time: int main() { try {
following code: self.dataTableViewController = [[DataTableViewController alloc] initWithStyle:UITableViewStylePlain]; CGRect tableViewRect = self.dataTableViewController.view.frame; tableViewRect.origin.x = 0.0f;
following code waits till dom ready jQuery(document).ready(function(){ what do i have to write to
Following code shows that the parameter, passed by reference, is copied when using boost::bind.
Following code works ok, except that it not zoom to the given points. If
Following code is simplified version of the code that I am trying to optimize.
Following code, when compiled and run with g++, prints '1' twice, whereas I expect
Following code iterates through many data-rows, calcs some score per row and then sorts
following code doesn't work with input: 2 7 add Elly 0888424242 add Elly 0883666666
The following code works great in IE, but not in FF or Safari. I

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.