SCCMWebService..::..RunPowerShellScript Method (String, String, String, String, Boolean)
Runs the given powershell script on remote computer using specified power shell path (e.g. \\Custom\\Remote).
Namespace:
SCCMWebServiceAssembly: SCCMWebService (in SCCMWebService.dll)
Syntax
[SoapHeaderAttribute] [WebMethodAttribute] public PowerShellResult RunPowerShellScript( string computerName, string psPath, string scriptFileName, string arguments, bool getResultString )
<SoapHeaderAttribute> _ <WebMethodAttribute> _ Public Function RunPowerShellScript ( _ computerName As String, _ psPath As String, _ scriptFileName As String, _ arguments As String, _ getResultString As Boolean _ ) As PowerShellResult
[SoapHeaderAttribute] [WebMethodAttribute] public: PowerShellResult^ RunPowerShellScript( String^ computerName, String^ psPath, String^ scriptFileName, String^ arguments, bool^ getResultString )
Parameters
- computerName
- Type: String
Name of the computer.
- psPath
- Type: String
The ps path.
- scriptFileName
- Type: String
Name of the script file.
- arguments
- Type: String
The arguments.
- getResultString
- Type: Boolean
if set to true [get result string].