Skip to main content
GameDev.net gamedev.net
🔒 Locked

CLSID_DirectPlay8Client Problem

Started by StarGamer_Nick Sep 5, 2003 at 3:46 PM 3 replies 1.2k views
Original Post
StarGamer_Nick
StarGamer_Nick
Hi Everyone I haven''t posted anything in a LONG period of time so I don''t know if anyone will remember me. (I''ve been working on a game in Shockwave which is now over). I haven''t programm in C++, and more specifically for DirectX, so I will need some pointers. I''m trying to create a test program but I''m having programming compiling the test Programm, I get the following message: " unresolved external symbol _CLSID_DirectPlay8Client " I''ve include DPlay8.h, and linked my program to DXGuid.Lib and DplayX.lib with no success. What does "CLSID_DirectPlay8Client" needs again to be functionnal ? (I''ve program with DirectPlay before so I know I''m missing something.. I just can''t seem to find out what it is.) Any kind of help would be appreciated . Thanks Nick
S1CA
S1CA
That should be enough to make it work.

Can you show us the lines of your code that have the CLSID_DirectPlay8Client on (probably a CoCreateInstance call).

- Do the DPlay tutorials in the SDK compile ?

- Is the file with the code in a C file rather than a CPP one ?

- Do any of the other headers you''re including have extern "C"''s in them ?

The fact that there''s an underscore in front of the name in the error message likely means either you''ve typed the name in with an incorrect extra leading underscore or the compiler/linker thinks the file is using C names.

- What compiler are you using ?

- Are the headers and libs you''re using the ones straight from the SDK or are they ones that someone has "converted" to work with another compiler such as Borland ? (i.e. whoever did the conversion may have screwed up the linkage settings)



--
Simon O''Connor
3D Game Programmer &
Microsoft DirectX MVP
Simon O'Connor | Technical Director (Newcastle) Lockwood Publishing | LinkedIn | Personal site
StarGamer_Nick
StarGamer_Nick
Hi and thanks for replying.

Here''s what I could find.

- Do the DPlay tutorials in the SDK compile ?

Answer: Nope, but I get a different problem with them, It''s the DialogBox functions which don''t work (something about the 4 Parameter not being of type of long). I''ve read somewhere that this error could happen with this function and that I should switch the function to the specific type.

Note: I''ve turn the DialogBox function into comment and I get the same problem now.

- Is the file with the code in a C file rather than a CPP one ?

Answer: The code is in CPP, I''m using Visual C++ 6.0, (I''ve just re-installed it on Windows XP)

- Do any of the other headers you''re including have extern "C"''s in them ?

Answer: Nope. (Except for the DPlay header, there''s no Extern "C"

BTW, I''ve created a MFC Dialog Box using the Wizard Creation APP.

I''m also tending toward thinking that it''s a link related problem. So I''ve check and double-check the DxGuid.Lib and the DPlayX.Lib and they''re both there.

- What compiler are you using ?

I''m using Visual C++ 6.0


- .. The Headers origin .. :

I took them directly from the SDK.


I''ve also added the link and the include directory in the Directory List with no luck.

Nick
cbenoi1
cbenoi1
> " unresolved external symbol _CLSID_DirectPlay8Client "

The GUIDs are not defined. Create another C file with only the include files you use for DX and put a define for INITGUID in front. Here''s an example:

#define INITGUID
#include <dplay8.h>
#include <dinput.h>
#include <mmsystem.h>
#include <dmusici.h>
#include <dsound.h>
#include "my_app_directplay.h"

This changes the DEFINE_GUID() macro from an external reference to a storage declaration.

-cb
StarGamer_Nick
StarGamer_Nick
Did that.. with no result..

But I''ve finally figure out what the problem was (D''OH!).

I know it was something simple, I simply forgot to put the DirectX Directory Path in my Include/Libary Director on the top of the list so it would look for it there first instead of taking the one within the other Library included with MS VC++
6.0.

All is working fine now


Nick


Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.