文档介绍:This document is created with the unregistered version of CHM2PDF Pilot
Author's Note
Visit my web site updated information regarding this book, including possible bug reports
and new code listings. You can address mail regarding problems in this book to ******@. Although
I'll also try to answer any easy questions you may have, I can't make any promises. I'm usually pretty busy, and my
cat refuses to learn the Windows API.
I'd like to thank everyone at Microsoft Press for another great job in putting together this book. I think this "10th
Anniversary Edition" of Programming Windows is the best edition yet. Many other people at Microsoft (including
some of the early developers of Microsoft Windows) also helped out when I was writing the earlier editions, and
these fine people are listed in those editions.
Thanks also to my family and friends, and in particular those more recent friends (you know who you are!) whose
support has made this book possible. To you this book is dedicated.
Charles Petzold
October 5, 1998
This document is created with the unregistered version of CHM2PDF Pilot
Chapter 1
Getting Started
This book shows you how to write programs that run under Microsoft Windows 98, Microsoft Windows NT ,
and Windows NT . These programs are written in the C programming language and use the native Windows
application programming interfaces (APIs). As I'll discuss later in this chapter, this is not the only way to write
programs that run under Windows. However, it is important to understand the Windows APIs regardless of what
you eventually use to write your code.
As you probably know, Windows 98 is the latest incarnation of the graphical operating system that has e the
de facto standard for patible puters built around 32-bit Intel microprocessors such as the 486
and Pentium. Windows NT is the industrial-strength version of Windows that runs on patibles as well as
some RISC (reduced instruction putin