Function Reference


_SafeArrayPutElement

Sets an element in a SafeArray at the specified indices.

_SafeArrayPutElement($pSafeArray, $aIndices, $vValue)

Parameters

$pSafeArray Pointer to the SafeArray.
$aIndices Array of indices for setting the element (AutoIt order).
$vValue Value to set (AutoIt type).

Return Value

Success: 0
Failure: 1 and sets @error:
1 - Invalid SafeArray pointer.
2 - Invalid dimensions or SafeArray access error.
3 - Mismatch between indices and SafeArray dimensions.
4 - Failed to set element (DllCall failure).
5 - SafeArray does not contain VARIANT elements.

Remarks

Uses AutoIt dimension order. Only supports SafeArrays of type VT_VARIANT.

Related

_SafeArrayGetElement, _CreateSafeArrayIndices