Named argument already specified
Use a named argument only once in the argument list of eachprocedure invocation. This error has the following causes and solutions:
You specified the same named argument more than once in a single call. For example, if the procedure
MySub
expects the named argumentsArg1
andArg2
, the following call would generate this error:Call MySub(Arg1 := 3, Arg1 := 5)
Remove one of the duplicate specifications.
You specified the same argument both by position and with a named argument, for example:
Call MySub(1, Arg1 := 3)
Remove one of the duplicate specifications.
For additional information, select the item in question and press F1 (in Windows) or HELP (on the Macintosh).
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.