Master the intricacies of application development with unmanaged C++ code—straight from the experts. Jeffrey Richter’s classic book is now fully revised for Windows XP, Windows Vista, and Windows Server 2008. You get in-depth, comprehensive guidance, advanced techniques, ...

See more details below
Windows via C/C++

Available on NOOK devices and apps  
  • NOOK Devices
  • Samsung Galaxy Tab 4 NOOK 7.0
  • Samsung Galaxy Tab 4 NOOK 10.1
  • NOOK HD Tablet
  • NOOK HD+ Tablet
  • NOOK eReaders
  • NOOK Color
  • NOOK Tablet
  • Tablet/Phone
  • NOOK for Windows 8 Tablet
  • NOOK for iOS
  • NOOK for Android
  • NOOK Kids for iPad
  • PC/Mac
  • NOOK for Windows 8
  • NOOK for PC
  • NOOK for Mac
  • NOOK for Web

Want a NOOK? Explore Now

NOOK Book (eBook)
BN.com price
(Save 42%)$55.99 List Price


Master the intricacies of application development with unmanaged C++ code—straight from the experts. Jeffrey Richter’s classic book is now fully revised for Windows XP, Windows Vista, and Windows Server 2008. You get in-depth, comprehensive guidance, advanced techniques, and extensive code samples to help you program Windows–based applications.

Discover how to:

  • Architect and implement your applications for both 32-bit and 64-bit Windows
  • Create and manipulate processes and jobs
  • Schedule, manage, synchronize and destroy threads
  • Perform asynchronous and synchronous device I/O operations with the I/O completion port
  • Allocate memory using various techniques including virtual memory, memory-mapped files, and heaps
  • Manipulate the default committed physical storage of thread stacks
  • Build DLLs for delay-loading, API hooking, and process injection
  • Using structured exception handling, Windows Error Recovery, and Application Restart services
Read More Show Less

Editorial Reviews

From Barnes & Noble
In Windows via C++, Jeffrey Richter and Christophe Nasarre have written the definitive guide to under-the-hood Windows programming with today's Visual C++. (This isn't a shock. Earlier versions of this book, titled Programming Applications for Microsoft Windows and Advanced Windows, respectively, were classics in systems-level Windows programming.)

This new edition has been thoroughly updated for Windows Vista's and Windows Server 2008's important new API features, in areas ranging from threading to security, exception handling to I/O. (There's also coverage of some significant WinXP and Windows Server 2003 API improvements that Richter and Nasarre haven't attended to before.)

Virtually no other authors offer more insight into how Windows really works from a developer's standpoint. Richter and Nasarre range from processes to memory management, DLL injection and API hooking to error reporting and recovery. What's more, their code examples are exceptionally solid: You can really rely on them. Bill Camarda, from the February 2008 Read Only

Read More Show Less

Product Details

  • ISBN-13: 9780735642461
  • Publisher: Pearson Education
  • Publication date: 12/12/2007
  • Series: Developer Reference
  • Sold by: Barnes & Noble
  • Format: eBook
  • Edition number: 5
  • File size: 9 MB

Meet the Author

Christophe Nasarre works for BusinessObjects, a multinational business-intelligence consultancy and training company that is focused on helping organizations gain better insight into their business through business intelligence solutions. He has worked as a technical editor on numerous Microsoft Press books.

Read More Show Less

Table of Contents

Dedication; Acknowledgments; Jeffrey’s Family; Christophe’s Family; Technical Assistance; Microsoft Press Editorial Team; Mutual Admiration; Introduction; 64-Bit Windows; What’s New in the Fifth Edition; Code Samples and System Requirements; Support for This Book; Required Reading; Chapter 1: Error Handling; 1.1 Defining Your Own Error Codes; 1.2 The ErrorShow Sample Application; Chapter 2: Working with Characters and Strings; 2.1 Character Encodings; 2.2 ANSI and Unicode Character and String Data Types; 2.3 Unicode and ANSI Functions in Windows; 2.4 Unicode and ANSI Functions in the C Run-Time Library; 2.5 Secure String Functions in the C Run-Time Library; 2.6 Why You Should Use Unicode; 2.7 How We Recommend Working with Characters and Strings; 2.8 Translating Strings Between Unicode and ANSI; Chapter 3: Kernel Objects; 3.1 What Is a Kernel Object?; 3.2 A Process’ Kernel Object Handle Table; 3.3 Sharing Kernel Objects Across Process Boundaries; Getting Work Done; Chapter 4: Processes; 4.1 Writing Your First Windows Application; 4.2 The CreateProcess Function; 4.3 Terminating a Process; 4.4 Child Processes; 4.5 When Administrator Runs as a Standard User; Chapter 5: Jobs; 5.1 Placing Restrictions on a Job’s Processes; 5.2 Placing a Process in a Job; 5.3 Terminating All Processes in a Job; 5.4 Job Notifications; 5.5 The Job Lab Sample Application; Chapter 6: Thread Basics; 6.1 When to Create a Thread; 6.2 When Not to Create a Thread; 6.3 Writing Your First Thread Function; 6.4 The CreateThread Function; 6.5 Terminating a Thread; 6.6 Some Thread Internals; 6.7 C/C++ Run-Time Library Considerations; 6.8 Gaining a Sense of One’s Own Identity; Chapter 7: Thread Scheduling, Priorities, and Affinities; 7.1 Suspending and Resuming a Thread; 7.2 Suspending and Resuming a Process; 7.3 Sleeping; 7.4 Switching to Another Thread; 7.5 Switching to Another Thread on a Hyper-Threaded CPU; 7.6 A Thread’s Execution Times; 7.7 Putting the CONTEXT in Context; 7.8 Thread Priorities; 7.9 An Abstract View of Priorities; 7.10 Programming Priorities; 7.11 Affinities; Chapter 8: Thread Synchronization in User Mode; 8.1 Atomic Access: The Interlocked Family of Functions; 8.2 Cache Lines; 8.3 Advanced Thread Synchronization; 8.4 Critical Sections; 8.5 Slim Reader-Writer Locks; 8.6 Condition Variables; Chapter 9: Thread Synchronization with Kernel Objects; 9.1 Wait Functions; 9.2 Successful Wait Side Effects; 9.3 Event Kernel Objects; 9.4 Waitable Timer Kernel Objects; 9.5 Semaphore Kernel Objects; 9.6 Mutex Kernel Objects; 9.7 A Handy Thread Synchronization Object Chart; 9.8 Other Thread Synchronization Functions; Chapter 10: Synchronous and Asynchronous Device I/O; 10.1 Opening and Closing Devices; 10.2 Working with File Devices; 10.3 Performing Synchronous Device I/O; 10.4 Basics of Asynchronous Device I/O; 10.5 Receiving Completed I/O Request Notifications; Chapter 11: The Windows Thread Pool; 11.1 Scenario 1: Call a Function Asynchronously; 11.2 Scenario 2: Call a Function at a Timed Interval; 11.3 Scenario 3: Call a Function When a Single Kernel Object Becomes Signaled; 11.4 Scenario 4: Call a Function When Asynchronous I/O Requests Complete; 11.5 Callback Termination Actions; Chapter 12: Fibers; 12.1 Working with Fibers; Memory Management; Chapter 13: Windows Memory Architecture; 13.1 A Process’ Virtual Address Space; 13.2 How a Virtual Address Space Is Partitioned; 13.3 Regions in an Address Space; 13.4 Committing Physical Storage Within a Region; 13.5 Physical Storage and the Paging File; 13.6 Protection Attributes; 13.7 Bringing It All Home; 13.8 The Importance of Data Alignment; Chapter 14: Exploring Virtual Memory; 14.1 System Information; 14.2 Virtual Memory Status; 14.3 Memory Management on NUMA Machines; 14.4 Determining the State of an Address Space; Chapter 15: Using Virtual Memory in Your Own Applications; 15.1 Reserving a Region in an Address Space; 15.2 Committing Storage in a Reserved Region; 15.3 Reserving a Region and Committing Storage Simultaneously; 15.4 When to Commit Physical Storage; 15.5 Decommitting Physical Storage and Releasing a Region; 15.6 Changing Protection Attributes; 15.7 Resetting the Contents of Physical Storage; 15.8 Address Windowing Extensions; Chapter 16: A Thread’s Stack; 16.1 The C/C++ Run-Time Library’s Stack-Checking Function; 16.2 The Summation Sample Application; Chapter 17: Memory-Mapped Files; 17.1 Memory-Mapped Executables and DLLs; 17.2 Memory-Mapped Data Files; 17.3 Using Memory-Mapped Files; 17.4 Processing a Big File Using Memory-Mapped Files; 17.5 Memory-Mappppppped Files and Coherence; 17.6 Specifying the Base Address of a Memory-Mapped File; 17.7 Implementation Details of Memory-Mapped Files; 17.8 Using Memory-Mapped Files to Share Data Among Processes; 17.9 Memory-Mapped Files Backed by the Paging File; 17.10 Sparsely Committed Memory-Mapped Files; Chapter 18: Heaps; 18.1 A Process’ Default Heap; 18.2 Reasons to Create Additional Heaps; 18.3 How to Create an Additional Heap; 18.4 Miscellaneous Heap Functions; Dynamic-Link Libraries; Chapter 19: DLL Basics; 19.1 DLLs and a Process’ Address Space; 19.2 The Overall Picture; Chapter 20: DLL Advanced Techniques; 20.1 Explicit DLL Module Loading and Symbol Linking; 20.2 The DLL’s Entry-Point Function; 20.3 Delay-Loading a DLL; 20.4 Function Forwarders; 20.5 Known DLLs; 20.6 DLL Redirection; 20.7 Rebasing Modules; 20.8 Binding Modules; Chapter 21: Thread-Local Storage; 21.1 Dynamic TLS; 21.2 Static TLS; Chapter 22: DLL Injection and API Hooking; 22.1 DLL Injection: An Example; 22.2 Injecting a DLL Using the Registry; 22.3 Injecting a DLL Using Windows Hooks; 22.4 Injecting a DLL Using Remote Threads; 22.5 Injecting a DLL with a Trojan DLL; 22.6 Injecting a DLL as a Debugger; 22.7 Injecting Code with CreateProcess; 22.8 API Hooking: An Example; Structured Exception Handling; Chapter 23: Termination Handlers; 23.1 Understanding Termination Handlers by Example; Chapter 24: Exception Handlers and Software Exceptions; 24.1 Understanding Exception Filters and Exception Handlers by Example; 24.2 EXCEPTION_EXECUTE_HANDLER; 24.3 EXCEPTION_CONTINUE_EXECUTION; 24.4 EXCEPTION_CONTINUE_SEARCH; 24.5 GetExceptionCode; 24.6 GetExceptionInformation; 24.7 Software Exceptions; Chapter 25: Unhandled Exceptions, Vectored Exception Handling, and C++ Exceptions; 25.1 Inside the UnhandledExceptionFilter Function; 25.2 Just-in-Time Debugging; 25.3 The Spreadsheet Sample Application; 25.4 Vectored Exception and Continue Handlers; 25.5 C++ Exceptions vs. Structured Exceptions; 25.6 Exceptions and the Debugger; Chapter 26: Error Reporting and Application Recovery; 26.1 The Windows Error Reporting Console; 26.2 Programmatic Windows Error Reporting; 26.3 Customizing All Problem Reports Within a Process; 26.4 Creating and Customizing a Problem Report; 26.5 Automatic Application Restart and Recovery; Appendixes; The Build Environment; The CmnHdr.h Header File; Message Crackers, Child Control Macros, and API Macros; Message Crackers; Child Control Macros; API Macros; About the Authors; Jeffrey Richter; Christophe Nasarre;

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star


4 Star


3 Star


2 Star


1 Star


Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation


  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously

    If you find inappropriate content, please report it to Barnes & Noble
    Why is this product inappropriate?
    Comments (optional)