In the code below, the first call to Perm.RevTCParms() works fine, but the second call returns "Invalid Callee".

It is a custom hand carved IDispatch Interface. At least at one level it is IDispatch, but there is no intelli-sense so it isn't complete either. (No Typelib).

VB seems happy to call most of the interface, but this one calling sequence has me stumped. The "parameter" is really an Index into an array/property . . . for some reason it correctly recognizes and does that if the index is a constant, but refuses if the index is a variable. (ByVal gives invalid type or something to that effect.)

Any ideas what to try?

I've tried every "type" for I that seems even remotely likely, but with no luck.

The same interface gets called no problems from Perl.

Frank

Private Sub Parameters_Click()
Dim Parm As Object
Dim i As Long
Dim x As Variant

Set Parm = APS.ParameterRetrieval2()
MsgBox Parm.RevTCParms(0)
i = 0
MsgBox Parm.RevTCParms(i)
End Sub