Out of curiosity, have you added [CmdletBinding()] just above the param() block?
↧
Out of curiosity, have you added [CmdletBinding()] just above the param() block?