Passing Arrays to Automation Servers
Earlier versions of Visual FoxPro passed arrays to COM objects, such as Automation servers created in Visual FoxPro, Visual Basic, or Visual C++, by value. That is, the array elements remained unchanged after a method call, and the COM object changes did not propagate to the elements on the client. This restriction prevented passing large amounts of data between Visual FoxPro and COM objects.
By default, an array that passes to a COM object is assumed to be a one-based array, meaning that the first array element, row, or column is referenced with 1, for example, MyArray[1], and is passed by value. However, some COM objects require that the array pass as a zero-based array, meaning the first array element, row, or column is referenced with 0, for example, MyArray[0], and by reference.
You can specify how to pass an array to an Automation server using the COMARRAY( ) function. For more information, see COMARRAY( ) Function.