Totaly new and trying to learn

Started by
11 comments, last by sphexion 16 years, 11 months ago
Okey I have not realyl done it before. I am going to try to design a engine that runs off of script files. Now to start off just the basics is'nt working out to well. I try to compile it and this comes.
------ Build started: Project: CreateDevice, Configuration: Debug Win32 ------
Compiling...
CreateDevice.cpp
Linking...
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__DefWindowProcA@16 referenced in function "long __stdcall MsgProc(struct HWND__ *,unsigned int,unsigned int,long)" (?MsgProc@@YGJPAUHWND__@@IIJ@Z)
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__ValidateRect@8 referenced in function "long __stdcall MsgProc(struct HWND__ *,unsigned int,unsigned int,long)" (?MsgProc@@YGJPAUHWND__@@IIJ@Z)
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__PostQuitMessage@4 referenced in function "long __stdcall MsgProc(struct HWND__ *,unsigned int,unsigned int,long)" (?MsgProc@@YGJPAUHWND__@@IIJ@Z)
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__UnregisterClassA@8 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__DispatchMessageA@4 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__TranslateMessage@4 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__GetMessageA@16 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__UpdateWindow@4 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__ShowWindow@8 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__CreateWindowExA@48 referenced in function _WinMain@16
CreateDevice.obj : error LNK2019: unresolved external symbol __imp__RegisterClassExA@4 referenced in function _WinMain@16
Debug/CreateDevice.exe : fatal error LNK1120: 11 unresolved externals
Build log was saved at "file://c:\Documents and Settings\kcd\My Documents\Visual Studio Projects\CreateDevice\Debug\BuildLog.htm"
CreateDevice - 12 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Advertisement
Which version of Visual Studio is it (if it's VS2005 Express Edition, make sure you read and follow the instructions here)?


jfl.
It looks like you are not linking to some library. For example, taking one of he unresolved functions and stripping it of its decoration (in this case __imp__), I pasted "ShowWindow" into google. First result was a MSDN reference which tells me this function lives in user32.dll, and the import lib is user32.lib. You need to tell your linker to link with it.
I'm going to move this to 'For Beginners' as setting up your IDE and linker inputs isn't really a DirectX issue....


Cheers,
Jack

<hr align="left" width="25%" />
Jack Hoxley <small>[</small><small> Forum FAQ | Revised FAQ | MVP Profile | Developer Journal ]</small>

Quote:Original post by rip-off
It looks like you are not linking to some library. For example, taking one of he unresolved functions and stripping it of its decoration (in this case __imp__), I pasted "ShowWindow" into google. First result was a MSDN reference which tells me this function lives in user32.dll, and the import lib is user32.lib. You need to tell your linker to link with it.


Yes, but typically, user32.lib is linked to by default.
Quote:Original post by jflanglois
Quote:Original post by rip-off
It looks like you are not linking to some library. For example, taking one of he unresolved functions and stripping it of its decoration (in this case __imp__), I pasted "ShowWindow" into google. First result was a MSDN reference which tells me this function lives in user32.dll, and the import lib is user32.lib. You need to tell your linker to link with it.


Yes, but typically, user32.lib is linked to by default.


I was wondering about that. But I suppose, were they any other functions (tat weren't in an automatically linked library) then my advice would be useful, a general answer to "unresolved symbols" if you like [smile].
Well I am using this new directx10 sdk
It added the librarys got added auto
but they are
E:\Program Files\Microsoft DirectX SDK (April 2007)\Lib\x86
instead of E:\Program Files\Microsoft DirectX SDK (April 2007)\Lib
Quote:Original post by rip-off
I was wondering about that. But I suppose, were they any other functions (tat weren't in an automatically linked library) then my advice would be useful, a general answer to "unresolved symbols" if you like [smile].

Don't misunderstand me, your advice is useful. It's just that I suspect that the OP has VC8 Express and hasn't set up the Platform SDK.


Quote:Original post by sphexion
Well I am using this new directx10 sdk
It added the librarys got added auto
but they are
E:\Program Files\Microsoft DirectX SDK (April 2007)\Lib\x86
instead of E:\Program Files\Microsoft DirectX SDK (April 2007)\Lib

That should be fine, as long as you are on an x86 platform. Have you looked at the link I posted above?


jfl.
one thing to remember don't use text script it runs very slow. its better to use binary script you know an array of bytes. I learned the hard way.
Quote:Original post by BlazingClaymore
one thing to remember don't use text script it runs very slow. its better to use binary script you know an array of bytes. I learned the hard way.

Wrong thread?

This topic is closed to new replies.

Advertisement