It consists of a documentation of the most frequently used functions, their explanations followed by examples. For more details about the other functions and a detailed technical explanation about introduction to safe arrays please refer to the MSDN documentation. A Safe Array is defined as an array that contains information about the number of dimensions and the bounds of its dimensions. This is one of the most commonly used COM data types. We will see some of the most commonly used SafeArray methods now.
Any array needs to be created and allocated memory before it is used.
This function creates a new array descriptor, allocates and initializes the data for the array, and returns a pointer to the new array descriptor. This indicates the type of data that can be stored in the array. All other types are legal. The number cannot be changed after the array is created. The structure is defined as follows.