Im utilising a 3rd party web service. One of the functions (called PerformAction) accepts a parameter of type myObject.

Code:
Dim myObject As Object
PerformAction(myObject)
This gave me the error "Value of type 'myObject' cannot be converted to '1-dimensional array of myObject'."

So i changed the declaration to

Code:
Dim myObject(0) As Object
That resolved the problem, for testing purposes but how could i pass in other values that are not known until runtime? e.g.

Code:
Dim myObject(0) As Object
Code:
Dim myObject(1) As Object
Code:
Dim myObject(2) As Object
Code:
Dim myObject(3) As Object
Code:
Dim myObject(4) As Object
So if 5 objects are selected at runtime how could i pass those objects to fit the above scenario mainly to ensure the PerformAction performs the required actions for all the elements. Hope this makes sense?

Thanks