Sign in to follow this  
johnnyBravo

visual c++, error LNK2019: unresolved external symbol

Recommended Posts

I've reinstalled my computer, and I just finished installing visual c++, and the platform sdk. I set the include and lib directories correctly, but I get these errors:
Quote:
main.obj : error LNK2019: unresolved external symbol __imp__DefWindowProcA@16 referenced in function "long __stdcall WndProc(struct HWND__ *,unsigned int,unsigned int,long)" (?WndProc@@YGJPAUHWND__@@IIJ@Z) main.obj : error LNK2019: unresolved external symbol __imp__PostQuitMessage@4 referenced in function "long __stdcall WndProc(struct HWND__ *,unsigned int,unsigned int,long)" (?WndProc@@YGJPAUHWND__@@IIJ@Z) main.obj : error LNK2019: unresolved external symbol __imp__DispatchMessageA@4 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__TranslateMessage@4 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__GetMessageA@16 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__CreateWindowExA@48 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__RegisterClassA@4 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__GetStockObject@4 referenced in function _WinMain@16 main.obj : error LNK2019: unresolved external symbol __imp__LoadCursorA@8 referenced in function _WinMain@16 C:\Documents and Settings\me\My Documents\Visual Studio 2005\Projects\i\\i\Debug\i.exe : fatal error LNK1120: 9 unresolved externals Build log was saved at "file://C:\Documents and Settings\me\My Documents\Visual Studio 2005\Projects\i\i\Debug\BuildLog.htm" i - 10 error(s), 0 warning(s)
Anyone have a clue what they mean? thx

Share this post


Link to post
Share on other sites
You haven't added the required library files to the linker settings. See the documentation for the mentioned functions and see what library you need to link.

Also, if you're using the express edition, the installation notes should tell you exactly what you need to do after installing the platform SDK in order to automatically link those libraries.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this