about SAFEARRAY** and the VTS_UNKNOWN type

I'm trying to call the HMPSVD method below (it is created
by a 3d party tool and it accesses a mainframe).
class CVariantArr : public COleDispatchDriver
CVariantArr(){} // Calls COleDispatchDriver
default constructor
CVariantArr(LPDISPATCH pDispatch) :
COleDispatchDriver(pDispatch) {}
CVariantArr(const CVariantArr& dispatchSrc) :
COleDispatchDriver(dispatchSrc) {}
// Attributes
// Operations
// _VariantArr methods
long HMPSVD(SAFEARRAY * * HMP10XC, long * tpurcode)
long result;
static BYTE parms[] = VTS_UNKNOWN VTS_PI4 ;
InvokeHelper(0x1, DISPATCH_METHOD, VT_I4,
(void*)&result, parms, HMP10XC, tpurcode);
return result;
// _VariantArr properties
There shall be 2 parameters in the varuant array
long p1;
char array p2;
I cannot figure out how to set up the array and to call
the method.
The SAFEARRAY * * is causing me problems. The VTS_UNKNOWN is wrong I think. And I tried to change it into VTS_I2 or VTS_VARIANT. It didn't work.
Any suggestions?? Thanks.

== blueeyesblue ==
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!