Another thing I learned on the way is that you cannot mix values of Platform Toolset
and Target Framework Version
.
The possible combinations I found where:
.NET 3.5 or less:
Platform Toolset
: v90, which will useVisual Studio 2008
runtime binaries,TargetFrameworkVersion
: v3.5 (or less),- In the preprocessor you can have
_WIN32_WINNT
defined (e.g._WIN32_WINNT=0x0500
)
.NET 4.0 or higher:
Platform Toolset
: v100, which will useVisual Studio 2010
runtime binaries,TargetFrameworkVersion
: v4.0 (or higher),- In the preprocessor you must not have the '_WIN32_WINNT=0x0500' defined
How to define these values:
Platform Toolset
– find it under: Project settings | General,TargetFrameworkVersion
- Unload the project, right-click on the unloaded project and select 'Edit'. Once the '*.*proj' file is open, modify the following line:<TargetFrameworkVersion>v3.5<TargetFrameworkVersion/>