
How to pass vbscript array variable to shared object using ByRef
I'm having problems accessing an array that is passed in to a shared
routine which is defined in an .exe It seems I can not figure out the
syntax to pass in the array, change it from within my shared function,
then have the script access the new array elements.
Here's my script snippet:
Dim MyArray(16)
shChange MyArray
Here's my shChange function declaration:
Sub shChange(ByRef MyArray() As Variant)
'change MyArray elements
End Sub
Even when I do not get a syntax error, I do not get the expected
values from my array.
What am I doing wrong? How can I avoid syntax errors AND access the
new array elements from the vb script?
Thanks for you help.
Mark