I have installed VisualStudio 2012 and was working for about 2 weeks with it. But now I wanted to start a C++ project (i am c# programmer usually) and I wrote some simple code. After that I wanted to compile it and I got lots of errors... there are no standart c-header files.
What I ve done: Created a new Win32 Project (empty project) Created code with these includes:
#include <windows.h>
#include <stdlib.h>
#include <string.h>
#include <tchar.h>
Windows.h is found the rest not. Does anyone has an idea? I also had look at the IncludeDirectories:
$(VCInstallDir)include
$(VCInstallDir)atlmfc\include
$(WindowsSDK_IncludePath)
Thats all. Does anyone has an idea?
Probably you found this known issue: https://connect.microsoft.com/VisualStudio/feedback/details/774158/re-installed-visual-studio-2010-and-c-standard-headers-are-missing If you install Visual Studio 2012 importing settings from Visual Studio 2010, and then uninstall it and reinstall it, the C++ standard headers are gone.
There is a solution that worked for me, proposed by Jeff at: https://social.msdn.microsoft.com/Forums/vstudio/en-US/a987f4fa-676f-4fda-ab69-2c6bcc2684c3/visual-studio-c-2012-standard-header-files-are-missing?forum=vssetup
which entails modifying a copy of vc_librarycore.msi with orca, and then running it. That will install part of the VC folder, where the include files are (Note that modifying the original vc_librarycore.msi directly as the answer suggests did not work, probably because of permissions, so I copied the whole vc_librarycore folder to a different directory). Also note that the UUIDs used in the answer may change according to the updates applied to Visual Studio 2012.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With