I believe the problem here is that variant array returned via COM needs to become a VB collection object, which does not happen immediately.
It happens when there is an intermediate variable, but it does not yet happen in the case of expression. In the latter case VBScript already sees what it treats as an object, but this object is a thin wrapper over variant array and it is not yet a collection object.
If you want a VBS one liner, this would work out:
Function TrueArray(ByVal Value)
TrueArray = Value
End Function
'MsgBox obj.Foo(0) -- Object not a collection: 'obj.Foo'
MsgBox TrueArray(obj.Foo)(0)
You can also implement a collection on the other side of property implementation and return it instead of safe array (ATL C++ code would use CComEnum<IEnumVARIANT...
helper, example).
I realize that your question is more about built-in scripting language capability that does the required conversion. Perhaps you could use some of the built-in functions to perform a similar trick to TrueArray
above.