Click to See Complete Forum and Search --> : Again! Member not found


April 20th, 1999, 02:17 PM
This is a repost of an two earlier posts, of which one with the erroneous title "Method not found".... I need some help desperately here....

I'm trying to wrap an in-process COM DLL using Visual C++ and MFC. I've created a class using the classwizard from the DLL (the only thing available to me, no TLB or anything else), and the classwizard neatly created 4 new classes from the DLL, which correlate with the classes that should be available from the documentation.
I've added AfxOleInit to the instation of the application and then try to run the following code:


// begin of code
ISession ceSession;
BOOL bSuccess = ceSession.CreateDispatch("ComHpceWl.Session");
if (!bSuccess) AfxMessageBox("Error...");

// now I'm calling any of the methods of the ceSession object
ceSession.SetSource("http://localhost/adminflow/cgi/bin/afwls.cgi")
// end of example code




But any of the methods I call returns back "Membernot found". The CreateDispatch call returns nozero (which is ok), but I can't seem to access any of the methods of my wrapped COM DLL.
Looking in the MSKB, all the references to this problem, don't really apply to this situation.
I have the suspicious feeling I'm overlooking something.
Any help urgently appreciated.

Regards,
Rob

gmadn
April 20th, 1999, 05:38 PM
The code looks ok. You may want to pass the second arg to the CreateDispatch, COleException and look at the status code for any leads.