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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T17:36:49+00:00 2026-06-07T17:36:49+00:00

This problem is a little hard to explain. I’ll do my best, hoping to

  • 0

This problem is a little hard to explain. I’ll do my best, hoping to make myself clear.

I’ve got 3 view controllers, let’s call them ‘View1’, ‘View2’ and ‘View3’.
On the top of their views, there are 3 buttons with the same names.
Each button presents modally its respective view.
I’ve done this simply by ctrl-dragging, in the storyboard, the View2 button to the View2 controller and the View3 button to the View3 controller.
View 1 is the starting controller, so its button is not connected to anything.

Now from View1 I can go to View2 and View3 by tapping those buttons.

In View2 and View3, when I tap the View1 button, I dismiss the modal view controller, going back to View1.

To go from View2 to View3, I’ve also connected the View3 button to the View3 controller.

Now what happens is:
if I go to View 3 from View1 and then tap on View1 button, I get back to View1 and that’s correct.
But if I tap on View2 from View3, I still get back to View1, and that’s not correct.

I’m stuck on this thing and can’t find a solution. I hope I made myself clear and that someone could help.
Thanks.

Edit: adding some images.
From left to right you can see the View1, View2 and View3 controllers.
The View1 is not a root controller, it comes from another controller.
The two pieces of code you see are respectively from the View2 and View3 controllers.

storyboard

View2 code

View3 code

  • 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-07T17:36:51+00:00Added an answer on June 7, 2026 at 5:36 pm

    It is hard to help you without understanding your view hierarchy. I can guess that your 1 view controller is your root view controller and that that’s why you get back to it.

    • What is your hierarchy?
    • Where do you call dismiss to your 3 view.

    And finally –

    It seems that a UISCrollView will be better for your scenario.
    Simply create a UISCrollView and add the views of your view controllers to it. then place a toolbar with button for each of the controllers and slide the scrollview programmatically to each view when a button is tapped.

    If you need more hemp with that I will be happy to help.

    Shani

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

Sidebar

Related Questions

This is a little bit of a hard problem to explain, so ill show
I'm having a trouble with this little problem. Let's say, I have an array,
This is a little hard to explain.. I am using tomcat 6.0 to test
I got a little problem, what I think, can't be hard. but somehow, I
Ok this is a little hard to explain but here I go. On View1
This seems to be a little hard to explain, but I will try my
The problem I am having is a little hard to explain, but I will
I have this little problem, that I cannot figure out which arguments to pass
I have this little problem. My client wanted two distinct swf on a web
I had this weird problem a little while ago and haven't been able to

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.