AnsweredAssumed Answered

vrf VT_SAFEARRAY

Question asked by soeren.hedemand on Dec 20, 2005
Is the documentation for this component even secretly available ?!?

A simple find will tell you that OLEAUT32.dll contains the following:

LPSAFEARRAY_Marshal
LPSAFEARRAY_Size
LPSAFEARRAY_Unmarshal
LPSAFEARRAY_UserFree
LPSAFEARRAY_UserMarshal
LPSAFEARRAY_UserSize
LPSAFEARRAY_UserUnmarshal
SafeArrayAccessData
SafeArrayAllocData
SafeArrayAllocDescriptor
SafeArrayAllocDescriptorEx
SafeArrayCopy
SafeArrayCopyData
SafeArrayCreate
SafeArrayCreateEx
SafeArrayCreateVector
SafeArrayCreateVectorEx
SafeArrayDestroy
SafeArrayDestroyData
SafeArrayDestroyDescriptor
SafeArrayGetDim
SafeArrayGetElement
SafeArrayGetElemsize
SafeArrayGetIID
SafeArrayGetLBound
SafeArrayGetRecordInfo
SafeArrayGetUBound
SafeArrayGetVartype
SafeArrayLock
SafeArrayPtrOfIndex
SafeArrayPutElement
SafeArrayRedim
SafeArraySetIID
SafeArraySetRecordInfo
SafeArrayUnaccessData
SafeArrayUnlock

But how would you access these functions?

/Sren

-----Original Message-----
From: ext Shawn Fessenden [mailto:shawn@testech-ltd.com]
Sent: 2005-12-19 16:44
To: VRF
Subject: RE: [vrf] VT_SAFEARRAY

> How to do it, please?

Unfortunately it won't be all that easy. VEE (and VB for that matter) construct passed arrays as VT_ARRAY, not VT_SAFEARRAY. The difference is that a VT_SAFEARRAY contains more information (hence requires more overhead). You can build a safe array using the api safe array manipulation functions. These all begin with SafeArray (SafeArrayCreateVector, SafeArraySetValues, etc). These are all in oleaut32.dll.

However, even if you do this it's not clear that you can successfully pass it. What VEE will own is a SAFEARRAY pointer - an int basically. The interface will probably reject that as well (but seeing as how it specifies ByRef maybe not).

Is the documentation for this component publicly available?
-SHAWN-

---
You are currently subscribed to vrf as: rsb@soco.agilent.com
To subscribe send a blank email to "join-vrf@it.lists.it.agilent.com".
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list,  email "vrf@agilent.com". 
If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".

Outcomes