Re: problem with co-create instance in ISAPI dll
- From: "Kevin Hirst" <kevin@xxxxxxxxxxxxxx>
- Date: Wed, 10 Aug 2005 13:40:43 -0400
Actually, the problem is (REGDB_CLASSNOTREG) when I use CLSCTX_LOCAL_SERVER,
but when I use CLSCTX_LOCAL_SERVER|CLSCTX_INPROC_SERVER, the web page from
the ISAPI never returns,
it just sits there and spins.
-K
"Kevin Hirst" <kevin@xxxxxxxxxxxxxx> wrote in message
news:uTY0GEdnFHA.576@xxxxxxxxxxxxxxxxxxxxxxx
> My name is Kevin, and I have emailed this to you since I cannot seem to
find
> a news server that will let me post to microsoft.public.vc.atl. Perhaps
you
> could just do me a favor and post it to this - or answer, but either way I
> would be incredibly appreciative. I have been trying to instantiate an
> Active X Object in an ISAPI dll, and the call to CoCreateInstance() has
been
> failing.
>
>
> CLSID clsid;
> CLSIDFromProgID(L"ccWeb3.MainClass", &clsid);
> CoInitialize(NULL);
>
> HRESULT hr = CoCreateInstance(clsid, NULL,
> CLSCTX_LOCAL_SERVER|CLSCTX_INPROC_SERVER, IID_IDispatch, (void
> **)&ccLibDisp);
>
> if(FAILED(hr)) {
> char buf[256];
> sprintf(buf, "CoCreateInstance() for \"ccWeb3.MainClass\"
> failed. Err=%08lx", hr);
> ::MessageBox(NULL, buf, "Error", 0x10010);
> _exit(0);
> }
>
> The return value for CoCreateInstance is always 0x80040154
> (REGDB_CLASSNOTREG).
>
> This is pretty standard code which has worked for me in the past with the
> same ActiveX Object on the same computer(but executed from the desktop).
In
> the ISAPI DLL I have verified that it has retrieved the proper GUID, but
the
> CoCreateInstance always fails with the not registered error. I have made
> sure that the security settings on the computer which holds the DCOM
object
> are correct (allow everybody) but this didnt change the results either.
Any
> help is appreciated.
>
> The DLL is registered under HKEY_CLASSES_ROOT and HKEY_LOCAL_MACHINE. I
> have already checked this.
>
> -Kevin
>
>
.
- Follow-Ups:
- Re: problem with co-create instance in ISAPI dll
- From: Kevin Hirst
- Re: problem with co-create instance in ISAPI dll
- References:
- problem with co-create instance in ISAPI dll
- From: Kevin Hirst
- problem with co-create instance in ISAPI dll
- Prev by Date: problem with co-create instance in ISAPI dll
- Next by Date: Passing a variant wrapped safe array in an event
- Previous by thread: problem with co-create instance in ISAPI dll
- Next by thread: Re: problem with co-create instance in ISAPI dll
- Index(es):
Relevant Pages
|