Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Directx linking error

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

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have set up mvc++ like the docs that come with directx tell you to. but every time I try and compile my program even if it is just void main() {} it gives me this error c:\program files\microsoft visual studio\myprojects\test\main.cpp(52) : fatal error C1010: unexpected end of file while looking for precompiled header directive I have tried going to the projects->settings->c/c++ tab and went to the precompiled headers section and clicked on not using precompiled headers like someone had suggested but when I did that I got errors saying it did not recomend the directx commands Can someone please help

Share this post

Link to post
Share on other sites
If you want to program with DirectX.
You need to build a project as "Win32 Application"
and then use
int WINAPI WinMain(HINSTANCE hinstance,
HINSTANCE hprevinstance,
LPSTR lpcmdline, int ncmdshow)
instead of main()

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!