Start-ProgramAs
PackageDeployment Module Help |
Package Deployment Module (DSM eScript Commands) |
Start-ProgramAs Cmdlet |
Version 1.0.0.3 |
Start-ProgramAs
Synopsis
Execute program under other logon as
Syntax
Start-ProgramAs [-FilePath] <String> [[-Arguments] <String>] [[-OnError] <String>] [[-Context] <String>] [[-WorkingDirectory] <String>] [-ContinueOnError] [-LeastPrivilege] [-PassThru] [-SecureParameters] [-SignedExitCode] [-Wait] [-Wow64] [[-ExitCodeVariable] <String>] [[-MaxWaitMinutes] <String>] [[-WindowStyle] <String>] [[-RunAs] <String>] [[-UserName] <String>] [[-Password] <String>] [[-Logon] <String>] [<CommonParameters>]
Description
Executes an application using an account other than the currently logged on user account. This ensures, for example, that an application can be executed with more permissions than the current logon allows. In contrast to RunAs the command RunAsEx additionally allows you to specify a return value which can be processed subsequently in the eScript.
Parameters
-Arguments <String> |
||||||
These parameters are transferred to the application |
||||||
|
-Context <String> |
||||||
User: Execution under user account; logging in HKEY_CURRENT_USER, i.e. for the user. |
||||||
|
-ContinueOnError <SwitchParameter> |
||||||
Continues script execution in spite of errors in the respective command |
||||||
|
-ExitCodeVariable <String> |
||||||
#TODO# |
||||||
|
-FilePath <String> |
||||||
Name of the application to be executed. |
||||||
|
-LeastPrivilege <SwitchParameter> |
||||||
#TODO# |
||||||
|
-Logon <String> |
||||||
NoProfile: The user profile is not loaded. No changes are written into the user profile after the application has been executed. |
||||||
|
-MaxWaitMinutes <String> |
||||||
The package is resumed after the amount of time entered, even if the application has not yet been terminated. |
||||||
|
-OnError <String> |
||||||
Done: Package is resumed with the next command. |
||||||
|
-PassThru <SwitchParameter> |
||||||
#TODO# |
||||||
|
-Password <String> |
||||||
The password for the selected user account |
||||||
|
-RunAs <String> |
||||||
UserName: The application is executed using the account information entered. |
||||||
|
-SecureParameters <SwitchParameter> |
||||||
The command or the variable are not written to log file. Use this option if you do not want the installation parameters or the password, for example, to be read out from the variable. |
||||||
|
-SignedExitCode <SwitchParameter> |
||||||
#TODO# |
||||||
|
-UserName <String> |
||||||
The user account under which the application is to be executed. |
||||||
|
-Wait <SwitchParameter> |
||||||
The package is only resumed when the application has been terminated. |
||||||
|
-WindowStyle <String> |
||||||
Normal: The application window of the executed program is displayed (Normal mode) |
||||||
|
-WorkingDirectory <String> |
||||||
#TODO# |
||||||
|
-Wow64 <SwitchParameter> |
||||||
For reasons of compatibilty, Ivanti DSM maps file and registry access to the default storage location for 32 bit applications (provided that the storage location differs from that of 64-bit applications). File access: whenever a 32-bit application attempts to access %windir%\System32, the access is redirected to %windir%\SysWOW64. Registry commands: when accessing HKEY_LOCAL_MACHINE\SOFTWARE the calls are redirected to HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node. The x64-switch stops this redirection of file and registry accesses when running the script command on a x64 computer; the eScript command runs on the specified path. CallScript command: the script runs in a 64-bit process. |
||||||
|
<CommonParameters> |
For more information about common parameters, type "Get-Help about_CommonParameters". |