Visual elements are important in the calculator app. This video shows how to connect all the visual elements of the calculator to code objects.
- [Instructor] Our next step is to connect…our user interface elements to our code,…so I'm going to head over to Main.storyboard.…I'll hide the document outline.…Then, I'm going to option + click ViewController.swift.…Now, to get a little bit more space,…I'll hide both the navigator and the utilities area.…Now, the first step is to connect our label,…so I'm going to right click and drag from my label…right underneath my class declaration.…Make sure it says Type UILabel.…We want Outlet for the connection.…We'll name this label and hit Connect.…
Label's now connected.…We'll scroll down a little bit,…and I'm going to connect the plus button,…the minus button, and the equals button.…Remember, the multiply button is going to be saved…for the challenge at the end of this chapter.…We'll start with the plus button,…so I'll click and drag from the plus button.…It's, again, right clicking and dragging,…underneath didReceiveMemoryWarning().…This is going to be the connection type of Action.…You can always confirm…that the type says UIButton underneath…
- Installing Xcode
- Creating an Xcode project
- Configuring the iOS Simulator
- Understanding variables
- Connecting visual objects to variables
- Understanding methods
- Connecting a button to a method
- Using conditional statements
- Setting up the user interface (UI)
- Building a complete iOS app
Skill Level Beginner
1. Set Up Your Coding Environment
Create an Xcode project4m 19s
2. Programming Building Blocks: Variables
3. Programming Building Blocks: Methods
4. Programming Building Blocks: Conditional Statements
5. Plan and Prepare the App
6. Build a Full Application
Next steps3m 11s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.