SafeArrayCopyData
A version of this page is also available for
4/8/2010
This function copies the source array to the target array after releasing resources in the target array.
This function is similar to SafeArrayCopy, except that the target array must be set up by the caller. The target is not allocated or reallocated.
Syntax
HRESULT SafeArrayCopyData(
SAFEARRAY FAR* psaSource,
SAFEARRAY FAR* FAR* psaTarget
);
Parameters
- psaSource
[in] Pointer to the safearray to be copied.
- psaTarget
[out] On exit, a pointer to the array referred to by psaTarget that contains a copy of the data in psaSource.
Return Value
Returns the HRESULT values shown in the following table.
Value | Description |
---|---|
S_OK |
Success. |
E_INVALIDARG |
The psa parameter was not a valid safearray descriptor. |
E_OUTOFMEMORY |
Insufficient memory to create the copy. |
Requirements
Header | oleauto.h |
Library | oleaut32.lib |
Windows Embedded CE | Windows CE 2.0 and later |
Windows Mobile | Windows Mobile Version 5.0 and later |