How to get an OLE array of objects?



I'm really scratching my head over this. I have an OLE object with a
method that takes an [out] parameter that is an array of other OLE
objects. What I'd like to do is to get that array of other OLE objects
and iterate through them, printing out a property from each one. I
don't know that much about OLE objects, can someone please help? I've
been Googling for a couple of hours and feel like I'm close, but I
can't find anything for that last little bit.

Here's what I need using semi-pseudocode that I know won't work right:

use Win32::OLE;
my $tree = Win32::OLE->new( 'Tree.Component' );
my @nodes = array();

# GetNodes is a method of TreeComponent that is defined like this:
# int GetNodes([out] TreeNode[])
# where TreeNode is another OLE object type

$tree->GetNodes(\@nodes); # This doesn't work...
for $node (@nodes) {
print $node{Name}."\n"; # Name is a property of TreeNode objects
}

Here's a piece of code that I found on another site that the author
claims to work, but not quite for what I need. This code gets a double
back:

my $arg4 = Variant( VT_R8 | VT_BYREF, 0.0);
my $service = Win32::OLE->new( '3rdPartyComponent.Service' );
$service->foo( 31, 4000, 28000, $arg4 );

....But I don't want doubles, I want an array of objects, and not being
familiar with OLE at all, I'm totally stumped.

I sure would appreciate any help anyone can give me on this!

.