Parameter type mismatch

Possible causes:

         An argument in a Sub or Function call does not have the correct data type.  For example, trying to pass a numeric value where a string is expected or vice versa produces this error.

         An argument in a Sub or Function call is a property and is passed by referenceproperties must be passed by value.  To pass an argument by value, either use ByVal in the Sub or Function argument list definition or enclose the argument in parentheses in the Sub or Function call.  For example, to pass the command button Caption property to a procedure,  Sub1 (Command1.Caption) is allowed, but  Sub1 Command1.Caption  produces this error.