Board index » cppbuilder » Parameter Passing Problem with ActiveX object
Joe Bingha
![]() CBuilder Developer |
Sun, 11 Nov 2001 03:00:00 GMT
Parameter Passing Problem with ActiveX object
We have a third party ActiveX object that has methods containing [out]
parameters of the form LPSAFEARRAY *. After much experimentation we have determined that these out parameters technique of passing an un-dimensioned pointer to an array i.e. Dim A() as long Call Object.Method(A()) To use these same methods in BCB4 it is necessary to create a pointer to i.e. Object->Method(LPSAFEARRAY * X) X is not NULL but *X is NULL. in BCB4 if you create LPSAFEARRAY X=0; // the compiler makes this NULL passing a pointer to this goes nowhere as it is also a NULL pointer. THe Creating LPSAFEARRAY * X and assigning *X=0 causes a run-time error. Can anyone suggest a work-around for this problem?? Thanks Joe Bingham |