Public Group

error windows.h

This topic is 3102 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

Sorry, if this is posted somewhere; however, I have looked and nothing seems to solve my issue. This is my code: //Beginning Game Programming, 2nd Edition //Chapter 1 - HelloWorld Program #include <windows.h> int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd) { MessageBox(NULL, "Motoko Kusanagi has hacked your system!", "Public Security Section 9", MB_OK | MB_ICONEXCLAMATION); } and I get the c1083 error. Could someone help me by telling me possible solutions and ways to ensure that my path to the header file is not blocked. I'm am using VS2008 pro edition with windows sdk aug 2009. If you need more info let me know. Thanks, Dave the humble novice programmer.

Share on other sites
Please post the exact and complete error message you're seeing.

Share on other sites
The message is:

Error 1 fatal error C1083: Cannot open include file: 'windows.h': No such file or directory

Thanks.

Share on other sites
Did you install the windows SDK?

http://msdn.microsoft.com/en-us/windows/bb980924.aspx

edit: oh, you said in your post that you did... did it correctly set up the include paths in visual studio? ( tools > options > projects and solutions > VC++ directories )

Share on other sites
This is what is in the include file in the VC++ directories:

$(VCInstallDir)include$(VCInstallDir)PlatformSDK\include

• 47
• 12
• 10
• 10
• 9
• Forum Statistics

• Total Topics
631373
• Total Posts
2999639
×