Chapter 9

Adding Outlets and Actions to Your RoadTrip Code

In This Chapter

arrow Connecting your user interface to your code

arrow Using the Assistant

arrow Taking advantage of the Connections inspector

arrow How connections are made at runtime

As I explain in Chapter 3, one of the things that the RoadTrip app will be able to do is send the image of a car to the top of the screen, have it turn around, have it move back down the screen, and then have it turn around again so it’s back where it started, all from a simple tap of the Test Drive button. Fun times.

For all that to happen, you’re going to need to add some logic to your code. You do that in a custom view controller, which gets detailed coverage in this very chapter — especially the bits about adding custom view controllers and connecting them to the view controllers you create in your storyboard. But that’s only one part of the story. For all the pieces to fit, you’ll need to be able to access the elements stipulated in your storyboard — elements like the car image — and then connect those elements to the code in your custom view controller.

Get iOS 6 Application Development For Dummies now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.