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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T16:06:47+00:00 2026-06-14T16:06:47+00:00

I have a view controller and it has connected via xib. In that xib

  • 0

I have a view controller and it has connected via xib. In that xib I have a seperate view and I connected this same view to 2 different IBoutlets and added this view to main view. But in the outlet the view which I added second is only visible. The first one is not able to see. Why?

  • 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-14T16:06:50+00:00Added an answer on June 14, 2026 at 4:06 pm

    Although it is possible to connect two outlets to the same view object, it is rarely advisable to doing so. In your case this is only one UIView (subclassed) object. Both IBOutlet ‘pointers’ refer to the same (individual) object.

    If you now setup both, first and then the second, layout them etc. then you will have the impression that only the second one is visible. That is what you are saying.

    Lets assume you have layouted your left view first and your right view second then it appears to you that only the right view is visible.
    If you now turn around the secuence of layouting statements (what ever that ist, position, size, frame, colour, …) and layout the right view and then the left view, only the left view will appear. This is simply because you managed to link the same object to two IBOutlets. By layouting the second one you simply overwrite the layout data that you set in the first hand.

    From what I read between the lines in your case I would suggest to create (probably duplicate) an additional UIView (or whatever subclass) in IB and link them accordingly to one IBOutlet each.

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

Sidebar

Related Questions

I have a UIViewController that I've added UITableViewDelegate to. This controller has a corresponding
I have a view controller that has a tableView in it. When I set
If I have a view controller that has an NSOperationQueue as an instance variable,
I have a view controller class that has to implement several protocols. Too keep
I have the problem that my view controller class has too many delegates and
I have a view MainView that has a navigation bar without any navigation controller,
So we have a real-estate-related site that has controller/action pairs like homes/view, realtors/edit, and
In my IB I have a navigation controller which has in it a view
I have a navigation controller which also has a table view. I want to
I'm making an application for the iPad. I have a view controll that has

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.