Hello everyone, I am trying to execute a powershell script as a trigger action. In my file path I have \\servername\C$\Windows\System32\WindowsPowerShell\v1.0\Powershell.exe -executionpolicy remotesigned -command C:\scripts\swpstest.ps1 -ComputerName ${N=SwisEntity;M=Caption}
My question is what method do I need to put into the powershell script in order to retrieve this parameter (node name)? Is it $args[0] ? Or param([string]$x) ?
For the path above I have also tried C:\Windows\System32\WindowsPowerShell\v1.0\Powershell.exe -executionpolicy remotesigned -command "C:\scripts\swpstest.ps1" -x "${N=SwisEntity;M=Caption}"
Any one know what I am doing wrong?