Hi!
What about something like following:
lnArrayLength=loCOMOjbect.GetArrayLength()
dimension MyArray(lnArrayLength)
loCOMOjbect.GetArrayData(@MyArray)
in the GetArrayData do the ACopy to the array parameter passed by reference:
lparameters paArray
EXTERNAL ARRAY paArray
acopy(this.aResults,paArray)
Note that you cannot re-dimention the array passed by reference inside of the COM object, you require to prepare its dimension in the client program as shown above.
HTH.
>How can I get an array FROM a VFP DLL ?
>
>When I run my class (vcx) it works fine, but when compiled to a dll it doesn't seem to return an array.
>
>?acopy( loCOMOjbect.aResults, laMyArray)
>yeilds "Feature not available" error.
>
>Are there any work arounds?
>
>ComArray() is for passing arrays TO comobjects.
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.comICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs
It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.