O'Reilly logo

Windows 8 Application Development with HTML5 For Dummies by Bill Sempf

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

Chapter 9

Programming to Contract

In This Chapter

arrow Allowing sharing with other apps

arrow Providing search functions

arrow Making use of devices

Once upon a time, if you needed to do something external to an application, like print to a printer or communicate with another program, you would copy your code from a magazine.

Okay, that was a long time ago. But it wasn’t long ago that you would copy the code from the Internet. Then, after a while, libraries appeared that you could copy into your program.

Eventually, services appeared that you could use. If you wanted to provide the information, you could create your own service. Finding those services, or getting people to find yours, was rather difficult at times, though. Still is.

Windows 8 is trying something totally new. Instead of depending on Internet-enabled code — either copied from or provided within — the commonly used interface code is provided as part of the operating system’s programming interface. It’s called a contract, and it’s taking Windows programming to new places.

Coding to a Whole New Tune

Windows 8 applications use charms to interface with the user, and contracts to communicate with the outside world. Charms are the navigational ...

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