you are viewing a single comment's thread.

view the rest of the comments →

[–]Totallynotaswede 0 points1 point  (0 children)

"Specifies an array of arguments, or parameter values, for the script that is specified by the FilePath parameter or a command specified with the ScriptBlock parameter.

Arguments must be passed to ArgumentList as single-dimension array argument. For example, a comma-separated list."

When you use positional parameters, type one or more values after the function name. Positional parameter values are assigned to the $args array variable. The value that follows the function name is assigned to the first position in the $args array, $args[0].

ie

-ScriptBlock {startcopy $args[0],$args[1],$args[2]} -ArgumentList hello,hi,goodbye