Build errors. windows.h etc. [SOLVED]

So, I was getting those errors and finally found solution working for me.

In visual studio 2013 go to: PROJECT / Properties / Configuration Properties / VC++ Directories.
If you have nothing in Inlude Directories and Library Directories, click on empty white bars and set to “inherit from parent or project defaults”.
After that I had succesful build.

I hope it helps.

Also make sure you are using:

  • Visual Studio 2013 windows desktop
  • you have Direct X SDK June 2010 installed
  • you have Windows SDK installed

Still after running compiled Unreal Editor, and making project it closes without warning after 10-20s.

Thanks, it helps

I had the same issue, found this (better) answer:

C++ code won’t build (cannot open include file ‘windows.h’)
https://answers.unrealengine.com/questions/12743/why-does-my-project-not-build-cannot-find-windowsh.html

=> FIX : don’t use ‘special’ chars in your Windows account name. This will prevent UAT from harvesting the environment variables from the MSVS scripts, thus tricking it into believing that no compiler is available.

I created a new account “Seb” (previously “Sébastien”) and this solved the issue!

(and this thread https://forums.unrealengine.com/showthread.php?98-Cannot-open-include-file-windows-h)

Note, if you have Visual Studio 2013 Community or Professional installed, either one of which are required by Unreal Engine 4, <Windows.h> is already included and packaged with your installation.

No, that is not the problem of adding windows.h, it’s a problem with UE4 GenerateProjectFiles not liking an accent on the user path.

No, I am sorry. I was referring to OP, that OP needs to not worry about installing Windows SDK, as it is part of Visual Studio 2013 and will be fully integrated with Visual Studio 2015 in the future.

Thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you thank you

I inexplicably had this in the “Exclude” path in VS:
$(VC_IncludePath);$(WindowsSDK_IncludePath);$(MSBuild_ExecutablePath);$(VC_LibraryPath_x86);

Deleting it all out fixed the problem for me, since it undoes the necessary Include directories.