VS. Compiling an MFC application may encounter environment variable errors

Source: Internet
Author: User
Tags visual studio 2010

  

Paste the error message that may appear first:
    1. "Winsdkver.h": No such file or directory
    2. "SDKDDKVer.h": No such file or directory
    3. (leave blank to add)
Problem Analysis:
    1. The SDK file is missing
    2. Multi-SDK Coexistence
    3. VS Multi-version coexistence causes problems with environment variables
    4. Target platform Pointing Error
    5. (leave blank to add)
Here is a simple solution: 1, the first is the simplest one-click solution "re-targeting the project"

(Looks like only VS2015 and VS2017 on the function)

    

    

Select the appropriate SDK version and determine that the operation resolves the 80% issue.

2, if the previous step is still prompted to have "Winsdkver.h": No such file or directory go to the Solution's properties page

    

The Windows SDK version and platform toolset on the Properties page will correspond to the version of the SDK you previously selected.

    

Change these two values to "inherit from parent or directory Defaults" and click OK and recompile.

There will be new error.

"Error MSB8020: Could not find the build tool for Visual Studio 2010 (Platform toolset =" V100 "). To build using the V100 build tool, install the Visual Studio 2010 build Tool. Alternatively, you can upgrade to the current Visual Studio tool by selecting the Project menu or by right-clicking the solution, and then selecting "Reset Solution Targets". ”

Then, according to the hint of error, go again to the "reset Project Target" to find that the option at this time is more than the first one

    

Select the highest (or corresponding) of the corresponding options, and then OK. You can then recompile to exclude error.

3, if face black or the same error error? 、

There are only two types of forced solutions, 1: Manually modify the SDK environment path; 2: Delete the redundant SDK environment

There are several solutions for the first approach

Here is a link to the reference:

lpx15312--cannot open include file: "SDKDDKVer.h": No such file or directory

hhh1108--vs2013 C + + error C1083: Unable to open source file: "SDKDDKVer.h", "stdio.h", "Tchar.h"

VS. Compiling an MFC application may encounter environment variable errors

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.