Creation of an C++ project

Hi everytime I try to create a project with a C+±Code I get this error:
The project could not be compiled. Would you like to open it in Visual Studio?

Running E:/Unreal/Epic Games/4.9/Engine/Binaries/DotNET/UnrealBuildTool.exe MyProject Development Win64 -project=“E:/Users/Crucial/Documents/Unreal Projects/MyProject/MyProject.uproject” -rocket -editorrecompile -progress -noubtmakefiles
@progress push 5%
Parsing headers for MyProjectEditor
Running UnrealHeaderTool “E:/Users/Crucial/Documents/Unreal Projects/MyProject/MyProject.uproject” “E:\Users\Crucial\Documents\Unreal Projects\MyProject\Intermediate\Build\Win64\MyProjectEditor\Development\UnrealHeaderTool.manifest” -LogCmds=“loginit warning, logexit warning, logdatabase error” -rocket -installed
Reflection code generated for MyProjectEditor in 6,7038926 seconds
@progress pop
Performing 8 actions (4 in parallel)
[2/8] Resource PCLaunch.rc
[3/8] Resource ModuleVersionResource.rc.inl
E:\Unreal\Epic Games\4.9\Engine\Source\Runtime\Launch\Resources\Windows\PCLaunch.rc(10) : fatal error RC1015: cannot open include file ‘windows.h’.
E:\Unreal\Epic Games\4.9\Engine\Source\Runtime\Core\Resources\Windows\ModuleVersionResource.rc.inl(3) : fatal error RC1015: cannot open include file ‘windows.h’.
PCH.MyProject.h.cpp
e:\unreal\epic games\4.9\engine\source\runtime\core\public\Windows/MinWindows.h(62) : fatal error C1083: Datei (Include) kann nicht ge?ffnet werden: “windows.h”: No such file or directory
-------- End Detailed Actions Stats -----------------------------------------------------------
ERROR: UBT ERROR: Failed to produce item: E:\Users\Crucial\Documents\Unreal Projects\MyProject\Binaries\Win64\UE4Editor-MyProject.dll
Total build time: 13,73 seconds
Any help would be great. :smiley:

Hello, MrGonzo

I am sorry to hear about your problem.

In this case, it is most likely that your Visual Studio installation is corrupt.

To fix the issue, please make sure that:

  1. Visual Studio’s InstallDir property is correct (it should look something like this:

C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE). You can check it in the registry.

  1. Environment variable Path is set correctly in your system (e.g. C:\Windows\System32). Also check whether VS120COMNTOOLS environment variable is appropriate (it should point to your actual Visual Studio installation location).

Finally, you can try repairing/reinstalling Visual Studio. Please don’t forget to reboot after installation.

Please note that problem may also occur due to multiple Visual Studio installations.

Hope this helped!

Have a great day!