SafeArrayAllocDescriptorEx function (oleauto.h)

Creates a safe array descriptor for an array of any valid variant type, including VT_RECORD, without allocating the array data.

Syntax

HRESULT SafeArrayAllocDescriptorEx(
  [in]  VARTYPE   vt,
  [in]  UINT      cDims,
  [out] SAFEARRAY **ppsaOut
);

Parameters

[in] vt

The variant type.

[in] cDims

The number of dimensions in the array.

[out] ppsaOut

The safe array descriptor.

Return value

This function can return one of these values.

Return code Description
S_OK
Success.
E_INVALIDARG
The argument psa was not valid.

Remarks

Because SafeArrayAllocDescriptor does not take a VARTYPE, it is not possible to use it to create the safe array descriptor for an array of records. The SafeArrayAllocDescriptorEx is used to allocate a safe array descriptor for an array of records of the given dimensions.

Requirements

   
Target Platform Windows
Header oleauto.h
Library OleAut32.lib
DLL OleAut32.dll