Join Todd Perkins for an in-depth discussion in this video Connecting all of the visual elements to code, part of Programming for Non-Programmers: iOS 8.
- View Offline
- Exercise Files
- You may have noticed that we didn't define…all of the variables and methods…that we discussed in the last movie.…That's because we're going to connect…all of the ones that are associated…with buttons and our text label to the code now.…So, in main.Storyboard, I'm going to turn on…the assistant editor, so I can see my storyboard…and my code file at the same time.…And I'm going to hide the navigator…and utilities areas so I get a little bit more space.…
And I'll scroll over in my storyboard here.…Remember, again you can always use the jump bar…to navigate to the correct file…if you're not seeing it either on the right or the left.…So, the first thing we'll do is start with that label.…So I'm going to, as we've done before, control drag…from the label into my code,…and I'm going to drag this between lines 17 and 18.…I want to drag it under my previously declared variables,…and I'll release my mouse button.…So, I should see the type as UILabel here.…
For connection, I'm going to leave Outlet.…I'll call this "label",…
If you find you'd like to learn more, see iOS App Development Essential Training, Foundations of Programming: Fundamentals, or any of the other programming courses in our library.
- Installing Xcode
- Creating an Xcode project
- Configuring the iOS Simulator
- Understanding variables
- Connecting visual objects to variables
- Understanding functions, methods, and selectors
- Connecting a button to a method
- Using conditional statements
- Setting up the user interface
- Connecting code elements to build an app
Skill Level Beginner
1. Setting Up Your Coding Environment
Creating an Xcode project3m 38s
2. Programming Building Blocks: Variables
3. Programming Building Blocks: Functions
4. Programming Building Blocks: Conditional Statements
Using conditional statements4m 11s
5. Building Your First Full Application
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
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.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.