Each argument to a ParamArray parameter can be of a different data type. Therefore, the parameter itself must be declared as an array of Variant type. You can also supply any number of arguments to a ParamArray. When the call is made, each argument supplied in the call becomes a corresponding element of the Variant array. For example:
Sub MySub(ParamArray VarArg())
. . .
End Sub
Call MySub ("First arg", 2, 3.54)
This error has the following causes and solutions:
Redeclare the parameter type as an array of Variant elements.
Use an explicit As Variant clause in the specification of the ParamArray parameter.
For additional information, select the item in question and press F1 (in Windows) or HELP (on the Macintosh).