Processes - Start
Declaration
<AMPROCESSES ACTIVITY="create" DOMAINNAME="text" REMOTEMACHINE="text" USERNAME="text" PASSWORD="encrypted text" PRIORITY="text (options)" EXECUTABLE="text" WORKINGDIR="text" ARGUMENTS="text" RESULTPID="Text" />
Description
Starts an instance of the specified process and optionally, populates a variable with the process identifier. This activity supports starting local or remote processes.
Practical usage
Used to start a process on the local machine or on a remote computer.
Parameters
Process
Property | Type | Required | Default | Markup | Description |
---|---|---|---|---|---|
Executable | Text | Yes | (Empty) | EXECUTABLE="c:\folder\theprocess.exe" | The path and file name to the executable (.EXE) file linked to the process in which to start. Press the folder icon to open an Explorer dialog in order to navigate to the specified executable file or enter the path and file name manually in the provided text-box. |
Working folder | Text | No | (Empty) | WORKINGDIR="c:\foldername\" | The initial directory for the process to be started. This value is normally populated upon entry of a value under the Executable parameter. This option is provided primarily for shells that must start an application and specify the application's initial drive and working directory. In most cases, no modifications are needed for this parameter. |
Arguments | Text | No | (Empty) | ARGUMENTS="text" | Specifies command-line options that are passed to the process to start. |
Set process priority to | Text (options) | No | Normal | PRIORITY="High" | The
priority level to set for the process to start. The available
options are:
|
Store process identifier in variable | Text | No | (Empty) | RESULTPID="Text" | The name of the variable in which to populate with the unique process identifier. Note that the process identifier is valid from the time the process is created until the time the process is terminated. |
Computer
Property | Type | Required | Default | Markup | Description |
---|---|---|---|---|---|
Local computer | --- | --- | --- | --- | If
enabled, specifies that the process to end resides on the local
machine. This parameter is enabled by default. If this parameter
is selected, the Another Computer
parameter becomes inactive. NOTE: This parameter does not contain markup and is only displayed in visual mode for task construction and configuration purposes. |
Another computer | --- | --- | --- | --- | If
enabled, specifies that the process to end resides on a remote
machine. The parameters below become active if this parameter
is enabled. NOTE: This parameter does not contain markup and is only displayed in visual mode for task construction and configuration purposes. |
Computer | Text | Yes | (Empty) |
|
The hostname or IP address of the remote machine that contains the process to end. This parameter is available only if the Another computer parameter is enabled. |
Domain | Text | Yes | (Empty) | DOMAINNAME="netauto" | The domain name of the remote machine that contains the process to end. This parameter is available only if the Another computer parameter is enabled. |
Username | Text | Yes | (Empty) | USERNAME="Bruce.Wayne" | A valid username used to log onto the remote machine that contains the process to end. This parameter is available only if the Another computer parameter is enabled. |
Password | Text | Yes | (Empty) | PASSWORD="batman" | The password corresponding to the username entered in the Username field. This parameter is available only if the Another computer parameter is enabled. |
Example
NOTE:
- Copy and paste the sample AML code below directly into the Task Builder Steps Panel.
- To successfully run the sample code, update parameters containing user credentials, files, file paths, or other information specific to the task to match your environment.
Description
This sample task starts the Photoshop.exe process locally.
Copy
<AMPROCESSES ACTIVITY="create" EXECUTABLE="C:\Program Files (x86)\Adobe\Adobe Photoshop CS3\Photoshop.exe" WORKINGDIR="C:\Program Files (x86)\Adobe\Adobe Photoshop CS3 " RESULTPID="TheProcess" PRIORITY="abovenormal" />