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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T05:58:50+00:00 2026-06-08T05:58:50+00:00

I have three view controllers, say A, B and C. I am navigating through

  • 0

I have three view controllers, say A, B and C. I am navigating through this views like follows;

A -presenting-> B -presenting-> C -presenting-> B

And from B, if I dismiss I want to navigate to C. But instead of that, now it is moving to A. I can’t use dismiss for navigation from C to B (some internal issues). So how can I fix this? Please help.

  • 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-08T05:58:52+00:00Added an answer on June 8, 2026 at 5:58 am

    You hit into a limitation of dismissModalViewController: it will remove all of your modal views (source):

    If you present several view controllers in succession, and thus build a stack of presented view controllers, calling this method on a view controller lower in the stack dismisses its immediate child view controller and all view controllers above that child on the stack. When this happens, only the top-most view is dismissed in an animated fashion; any intermediate view controllers are simply removed from the stack. The top-most view is dismissed using its modal transition style, which may differ from the styles used by other view controllers lower in the stack.

    What you could do is using a UINavigationController and simply push/pop controllers on to it according to your requirements.

    Alternatively, you could simply display the views managed by the various controllers you have by directly calling addSubview on your top view and making sure they cover the whole screen and that the managing controller is correctly retained/released (the view is automatically when you add/remove it to another view).

    As a hint, you could do it like this:

    1. where you have presentModal..., use addSubview;

    2. where you have dismiss..., use removeFromSuperview;

    3. store a reference to any view controller whose view you manage like I suggest here in retain/strong property.

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

Sidebar

Related Questions

I want to show an image view for three like on/off,if any one have
I have three table views inside a view controller (going to show/hide table views
I have three views each represented by a View controller named firstVC, secondVC and
I have three view on the same place. I need to show them like
I have table View with grouped style with three sections. Get information from dictionary
Let's say I have a PHP Model-View-Controller framework that maps an address like http://example.com/admin/posts/edit/5
Say, I have this in one of the controllers: def show case current_user.role when
I have 5 view controllers(say A,B,C,D,E) in my navigation stack. ViewController E is in
I have created a web-service app and i want to populate my view controllers
I have two table view controllers. Say TableViewController1 and TableViewController2 . I push TableViewController2

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.