Passing Parameter in Shell Script Test (Powershell)

All questions related to installations, configurations and maintenance of Advanced Host Monitor (including additional tools such as RMA for Windows, RMA Manager, Web Servie, RCC).
Post Reply
Gavin
Posts: 58
Joined: Thu Sep 24, 2009 8:44 am

Passing Parameter in Shell Script Test (Powershell)

Post by Gavin »

Hi

Using the Shell Script option and an RMA I want to pass the "Params" property in the test to the shell script I have. Does anyone have an example of how this works and how I can them read the parameter in a powershell script?

Thanks in advance
KS-Soft Europe
Posts: 2832
Joined: Tue May 16, 2006 4:41 am
Contact:

Post by KS-Soft Europe »

For powershell you may use $args[N]. Where N - parameter index starting from 0.
E.g.

Code: Select all

$statusOk="ScriptRes:Ok:"
$res=$args[0]
echo $statusOk$res
Post Reply