Curtis Justus
2/21/2007 3:07:00 PM
Hi everybody,
I am baffled by this problem and was hoping that somebody could help me out.
I have a COM DLL that was created by Delphi that I am calling indirectly
within my web service. The WS is calling a .NET component that calls the
COM DLL. I unit test the .NET component and it works fine. As soon as I
make calls from within the web service, I get the following error:
Unable to cast COM object of type 'ABDelphiLib.MathLibClass' to interface
type 'ABDelphiLib.IMathLib'. This operation failed because the
QueryInterface call on the COM component for the interface with IID
'{A48ACC15-ADCB-4759-BA41-C9541E97601E}' failed due to the following error:
No such interface supported (Exception from HRESULT: 0x80004002
(E_NOINTERFACE)).
Trace Information: at ABDelphiLib.MathLibClass.RoundFloat(Double rInput,
Int32 iDigits)
I looked at the interop file that Visual Studio created, and it has the same
results as one that I would create with tblimp. I made sure the interop
assembly is in the BIN directory of my web service app. I also made sure
the native com component is in that directory, although it was already
registered with regsvr32. I am running the tests against the same machine.
Why doesn't this work within the web service when it works when I test the
..Net assembly?
Thanks in advance,
cj