Project out of date - The Windows SDK version 8.1 was not found

  • Thread starter Thread starter Robert 1234
  • Start date Start date
R

Robert 1234

Guest
I installed Visual Studio 2015 with update 3. One of the items the installer programs explicitly said it would download and install was Windows 8.1 SDK.

when i do File>New>Project and choose the default console application it produces this code:

// ConsoleApplication2.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"


int main()
{
return 0;
}


When I press F5 (Start Debugging) it warns me "The Project is out of date. Would you like to build it?"

How can this brand new project be "out of date"?

How do I stop it from being "out of date"?

If I choose "Yes" to build it, teh build fails with four errors.

Severity Code Description Project File Line Suppression State
Error (active) cannot open source file "stdio.h" ConsoleApplication3 c:\Users\Robert\Favorites\Documents\Visual Studio 2015\Projects\ConsoleApplication3\stdafx.h 10
Error (active) cannot open source file "tchar.h" ConsoleApplication3 c:\Users\Robert\Favorites\Documents\Visual Studio 2015\Projects\ConsoleApplication3\stdafx.h 11
Error (active) cannot open source file "SDKDDKVer.h" ConsoleApplication3 c:\Users\Robert\Favorites\Documents\Visual Studio 2015\Projects\ConsoleApplication3\targetver.h 8
Error MSB8036 The Windows SDK version 8.1 was not found. Install the required version of Windows SDK or change the SDK version in the project property pages or by right-clicking the solution and selecting "Retarget solution". ConsoleApplication3 C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms\Win32\PlatformToolsets\v140\Toolset.targets 34


The error says "

Install the required version of Windows SDK or change the SDK version in the project property pages or by right-clicking the solution and selecting "Retarget solution"."

I have followed the re-targeting advice but that does not solve the problem.

I have also re-downloaded and installed the Windows 8.1 SDK from elsewhere on this site but that also does not solve the problem.

What more do i need to do to get this basic default program to compile?

Continue reading...
 
Back
Top