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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T06:37:28+00:00 2026-05-16T06:37:28+00:00

I have 2 views. One is the ‘viewheader’ and the other is the ‘viewContent’

  • 0

I have 2 views. One is the ‘viewheader’ and the other is the ‘viewContent’ (added as subview).

‘viewContent’ contains a TableView (based on UINavigationController) and the TableView can drill down to a DetailView (UIViewController). (see Image below)

My Question is: How can I remove (pop) the DetailView, with a UIButton FROM the ‘headerView’.

The goal is to create a fixed Navigation, and only change (animate) the lower Content.

Thanks

// add "fixed" Header
- (void)loadView {
    viewHeader = [[HeaderViewController alloc] initWithNibName:@"HeaderViewController" bundle:nil];
    self.view = viewHeader.view;
}

// add content view
- (void)viewDidLoad {
    [super viewDidLoad];

    viewContent = [[MainContentViewController alloc] initWithNibName:@"MainContentViewController" bundle:nil];

    CGRect viewFrame = CGRectMake(0.0f, 164.0f, 320, 316);
    UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:viewContent];
    [navController setNavigationBarHidden:YES];
    [navController.view setFrame:viewFrame];
    viewHeader.contentNavView = navController; // <<<< CAN'T POP THE VIEW by passing UINavigationController to "header view"
    [self.view addSubview:navController.view];
}
  • 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-16T06:37:28+00:00Added an answer on May 16, 2026 at 6:37 am

    I Found my mistake. The definition of ‘contentNavView’ inside ‘viewheader’ was wrong

    Changed it from UIViewController to UINavigationController.

    @interface HeaderViewController : UIViewController {
        UINavigationController *contentNavView;
    }
    ...
    

    Calling

    [contentNavView pushViewController:aViewController animated:NO];
    

    works.

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

Sidebar

Related Questions

I have 2 views 1 view has NSTextFields (viewA) the other one (viewB) just
In one of my iPhone projects, I have three views that you can move
I have two views one of them is in landscape and other in portrait.
i have two views and one viewcontroller: one contains UIImageView with image, second have
I have 2 views one is a scroll view and the other is a
I have many views that I want to communicate with one other view. We'll
I have 2 views in my application. In one of the views I can
Good Morning, I have 2 views: ICCUDays which contains one record per account with
I have two views within one .xib (one view for landscape, another for portrait).
I have 2 customer views one for create and one for edit. I am

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.