I'm making my first DirectX program and when I try to compiler I get this error:
DirectX Test error LNK2019: unresolved external symbol _DirectDrawCreate@12 referenced in function "bool __cdecl init(struct HWND__ *)" ( init@@YA_NPAUHWND__@@@Z)
and it point to this line in my code:
hr = DirectDrawCreate( NULL, &g_pDD, NULL );
hr is a variable of type HRESULT and g_pDD is a var of type LPDIRECTDRAW
please help

linker problem
Wayne Taylor
It is recommended to not longer use DirectDraw. You should use Direct3D instead:
http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=76924&SiteID=1
Your linker problem occurs because you have not added the ddraw.lib to your project. You can do this with the following code:
#pragma comment (lib, "ddraw")
Edward Kim