unable to figure out why Xcode is not working expectably

Hello, guys! I am a new student learning swift for ios development in Udemy.com. I am following one of the examples to create a button which can turn the screen colour from white to red; however, I don't understand why the ios simulator is not showing me what is suppose to happen. Instead, it's just showing me a black screen. Thank you in advanced.

Replies

Jack:


Welcome to the forums.


What version Xcode?


Did you search yet on: simulator black screen


Why are you taking lessons from somewhere that doesn't offer support while learning? Did they send you here instead?


Let's review today's DevForum lesson:

- Remember to search (via 'Search', upper right) a forum before posting to help save time waiting for a reply and lessen the risk of posting a question that may have already been asked before - tip: be sure to also/always scan the MLT links below.

- Remember that when asking a question involving a tool you're using, to always provide not only that tool's name, but it's version number as well.

- Comment greetings are best kept gender neutral so as to be as inclusive as possible. You don't want to alienate someone that might otherwise be willing to help, right off the bat. 😉


Good luck.


KMT

Did you do the following :


- Create a new IOS project

- Drop a button object in the view in the main storyboard

- run


Then you should see a white screen with a button that still does nothing


When you look at the storyboard, do you see an arrow on the left pointing to the viewController ? If not, that's the problem.

Select the viewController ; in the inspector panel on the right select the attributes inspector ; the checkbox must be ON.


Retest.