O'Reilly logo

Developing for Apple Watch by Jeff Kelley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Adding User-Interface Elements

If you select your watch app target’s scheme in Xcode by clicking HelloWatch in the toolbar and selecting HelloWatch WatchKit App or selecting Product Scheme HelloWatch WatchKit App, and then you build and run (by pressing R), you’ll be greeted with a mostly blank Apple Watch screen with the time in the upper-right corner, a charging icon, and nothing else. Congratulations: your app is running! Now let’s make it do something. Let’s add a button and a label to this screen; the button will set the title of the label when you tap it. Head to the watch app’s storyboard file in Xcode. If you don’t see it, open the Project Navigator by pressing 1 and expanding the HelloWatch WatchKit App group; it’s named Interface.storyboard ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required