Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Nicoara Talpes
7,354 PointsView Hierarchy does not show anything
Hi.
My ViewHierarchy does not show anything - just a blank screen. I have tried different devices as simulators - iphone 5,5s,6, all with iOS 9.2. My XCode is 7.2.
I don't know what to do at this point. Thanks
2 Answers
Paul Brazell
14,371 PointsDid you make sure that you have a view controller set as the initial view controller?
Daniel Cohen
5,785 PointsSame issue for me but I figured this was because I'm running OS X in a virtual machine at the moment. (XCode 7.3.1)
Nicoara Talpes
7,354 PointsNicoara Talpes
7,354 PointsHello Paul, Thanks for helping out. The initial controller is the Navigation Controller. Anything else throws an error at the line in AppDelegate.swift: let navController = window!.rootViewController as! UINavigationController
Also, the same behavior happens with the FunFacts project from the 'build a simple iphone app with swift' course , where I have the ViewController set as my Initial ViewController. (I am following the steps here: https://developer.apple.com/library/ios/recipes/xcode_help-IB_storyboard/Chapters/SetInitialController.html)
Nicoara Talpes
7,354 PointsNicoara Talpes
7,354 PointsHello Paul, Do you have an update for me ? Thanks.