IT Bookworm Blog

Nov 18 2013   3:30PM GMT

Book excerpt: Building Windows 8 Apps

Michael Tidmarsh Michael Tidmarsh Profile: Michael Tidmarsh

“This excerpt is from the book, Building Windows 8 Apps with C# and XAML by Jeremy Likness, published by Addison-Wesley Professional, October 2012, ISBN-10: 0-321-82216-1. For more info please visit the publisher site:

The New Windows Runtime

THE WINDOWS RUNTIME (WINRT) IS AN ENTIRELY NEW framework for Windows that provides developers a multi-language API for creating  applications on Windows 8. Windows Store applications are full-screen applications that are tailored for specific devices, touch interactions, and the new Windows 8 user interface. Windows Store applications are also referred to as tailored applications because they adapt to the target device. It is also possible to build traditional desktop applications on Windows 8. The term “Windows 8 application” in this book will refer to the non-desktop, Windows Store version of applications that use WinRT. The introduction of WinRT is one of the largest paradigm shifts in the Windows development world since the introduction of .NET in late 2000.

In this chapter, you will look back at prior development frameworks for Windows and learn how the rising popularity of Natural User Interfaces (NUI) prompted Microsoft to respond with the bold new Windows 8 platform. You will learn about Windows 8 applications and the various languages in which they are written. I will also share how existing XAML-based technologies like WPF and Silverlight fit into the new Windows runtime.

Looking Back: Win32 and .NET

“I can change my mind faster than Bill Clinton.”
—Jay Leno at the Windows 95 Launch Party, referring to the new Windows task bar

In 1985, the first version of Windows was released without much fanfare. It wasn’t a full operating system, but a layer that sat on top of the console-based MS-DOS and was called MS-DOS Executive, as shown in Figure 1.1. A decade later, things changed dramatically with the launch of Windows 95. Bill Gates appeared on a massive stage in front of the now iconic “Start button” for Windows with talk show host Jay Leno and demonstrated the powerful new operating system. It caught on quickly to the tune of the Rolling Stones’ song “Start Me Up” and left close competitors like Apple behind in its wake.

Windows 95Figure 1.1: MS-DOS Executive

To write software for Windows 95, shown in Figure 1.2, developers used an Application Programming Interface (API) that had been developed several years earlier known as Win32. At the time, Microsoft was bridging the gap between legacy 16-bit systems and the newer 32-bit machines and conveyed the new support in the name of their API. Win32 exists today (now more appropriately referred to as the Windows API) at the core of all Windows operating systems despite the introduction of newer frameworks and platforms that abstract it away. The API was considered extremely powerful and flexible at the time it was introduced but placed a tremendous burden on the developer to handle many low-level operations required to display a form and interact with the user.

Windows 95-2Figure 1.2: Windows 95

The following code is all that is required to print the text “Hello, World” using the C++ programming language:

int main()
cout << "Hello World" << endl;
return 0;

 Comment on this Post

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

Share this item with your network: