This version of the Microsoft® Platform SDK targets applications for Microsoft Windows® 95, Microsoft Windows NT® 4.0, Microsoft Windows® 98, Microsoft Windows Millennium Edition (Windows Me), Microsoft Windows 2000, Microsoft Windows XP, and Microsoft Windows .NET Server using the header file conventions below.
The makefiles generated by Microsoft Visual C++® 5.0 and 6.0 target Windows NT 3.51 by default. To use functions introduced in Windows NT 4.0 or later, which are protected by conditional code, you must define the appropriate macros. Otherwise, you will receive the following error message from the compiler: error C2065: undeclared identifier. You may also need to ensure that the INCLUDE environment variable has the path to the Platform SDK header files listed before the path to the Visual C++ header files. Otherwise, you will receive error C2065 for items that were introduced after Visual C++ was released. The following table indicates the macros you must define to target each system using the SDK headers.
Minimum System RequiredMacros to DefineWindows 95 and Windows NT 4.0WINVER=0x0400Windows 98 and Windows NT 4.0_WIN32_WINDOWS=0x0410 and WINVER=0x0400Windows NT 4.0_WIN32_WINNT=0x0400 and WINVER=0x0400Windows 98_WIN32_WINDOWS=0x0410Windows 2000_WIN32_WINNT=0x0500 and WINVER=0x0500Windows Me_WIN32_WINDOWS=0x0490Windows XP and Windows .NET Server_WIN32_WINNT=0x0501 and WINVER=0x0501Internet Explorer 3.0, 3.01, 3.02_WIN32_IE=0x0300Internet Explorer 4.0_WIN32_IE=0x0400Internet Explorer 4.01_WIN32_IE=0x0401Internet Explorer 5.0, 5.0a, 5.0b_WIN32_IE=0x0500Internet Explorer 5.01, 5.5_WIN32_IE=0x0501Internet Explorer 6.0_WIN32_IE=0x0560 or_WIN32_IE=0x0600If you are writing your own makefile, the macros in Win32.mak can help you use the correct conventions. The value of _WIN32_WINNT is set in Win32.mak, depending on the platform you choose to target. For more information, see Building Applications Using Win32.mak.
The Platform SDK headers use guard statements to determine the system on which each function is supported. The following table describes these statements.
Guard StatementMeaning#if _WIN32_WINNT >= 0x0400Windows NT 4.0 and later. It is not implemented in Windows 95.#if _WIN32_WINDOWS >= 0x0410Windows 98. The image may not run on Windows 95. #if _WIN32_WINDOWS >= 0x0490Windows Me. The image may not run on Windows 95/98, Windows NT, or Windows 2000.#if _WIN32_WINNT >= 0x0500Windows 2000. The image may not run on Windows 95/98 or Windows NT.#if _WIN32_WINNT >= 0x0501Windows XP. The image may not run on Windows 95/98, Windows NT, Windows Me, or Windows 2000.#if _WIN32_IE >= 0x0300Internet Explorer 3.0 and later.#if _WIN32_IE >= 0x0400Internet Explorer 4.0 and later.#if _WIN32_IE >= 0x0401Internet Explorer 4.01 and later.#if _WIN32_IE >= 0x0500Internet Explorer 5.0 and later.#if _WIN32_IE >= 0x0501Internet Explorer 5.01 and later.#if _WIN32_IE >= 0x0560Internet Explorer 6.0 and later #if _WIN32_IE >= 0x0600Internet Explorer 6.0 and laterFor example, if you do not include Win32.mak in your makefile, you need to explicitly define _WIN32_WINNT as 0x0500 to use the Windows 2000-specific material in the header files.
There are functions in Windows 95 OEM Service Release 2 that are guarded by (_WIN32_WINNT >= 0x0400), such as the Cryptographic Application Programming Interface (CryptoAPI). If you are writing an application specifically for Windows 95 OEM Service Release 2, and you want the header files to provide compile time access to these functions, it is necessary to define _WIN32_WINNT as 0x0400. Note that an application using these functions does not run correctly on the retail release of Windows 95. In general, applications expected to run on Windows 95 should be built without defining _WIN32_WINNT.
This version of the Platform SDK can also be used to build applications for 64-bit Windows. The header files use new data types that allow you to build both 32- and 64-bit versions of your application from a single source code base. For more information, see Getting Ready for 64-bit Windows.