Hi,
I have a COM object that I'm trying to use from within a VC++ dll. I'm
pretty sure that the COM object was written in VB although we didn't write
it. I registered the dll and have been able to successfully use it from
within a VB.NET program.
I need to be able to access it from within a VC++ dll that will end up being
an extended stored procedure. I've been able to get the dll loaded and
apparently executing but never returning anything other than a zero value to
the calling routines.
Any help on what I'm doing wrong is welcome.
Here's what the code looks like:
HRESULT hr = CoInitialize(NULL);
if ( FAILED(hr))
{ Return error }
_bstr_t bClr = "value B";
_bstr_t bPd = "Value C;
ICPSQLPtr pICPPd ( __uuidof( CPSQL ) );
VARIANT_BOOL retBool = pICPPd->ValueIsValid(bClr,bPd);
CoUninitialize();
The signature for the method in the class is ( _bstr_t, _bstr_t ) and
returns a VARIANT_BOOL as shown.
I'm passing values in that return a true value when the same COM object is
executed from a VB.NET program, yet I can not get anything other than a zero
to return back to the program.
Any hints?
TIA, Jim