Processes - Start

 

Declaration

<AMPROCESSES ACTIVITY="create" DOMAINNAME="text" REMOTEMACHINE="text" USERNAME="text" PASSWORD="encrypted text" PRIORITY="options" EXECUTABLE="text" WORKINGDIR="text" ARGUMENTS="text" RESULTPID="Text" />

See Also

Processes - Set Affinity | Processes - Set Priority | Processes - Get Info | Processes - End

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

General Properties

Property

Type

Req’d

Default

Markup

Description

Executable

Text

Yes

(Empty)

EXECUTABLE="c:\folder\theprocess.exe"

The path and file name to the executable (.EXE) of the process in which to start.

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

 

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:

  • Normal (default) - Specified for a process with no special scheduling needs.

  • Below Normal - Indicates a process that has priority above Idle but below Normal priority.

  • Above Normal - Indicates a process that has priority above Normal but below High priority.

  • Idle - Specified for a process with threads that run only when the system is idle. The threads of the process are preempted by the threads of a process that run in a higher priority class, for example, a screen saver. The idle-priority class is inherited by child processes.

  • High - Specified for a process that performs time-critical tasks that must be executed immediately. The threads of the process preempt the threads of normal or idle priority class processes.

  • Realtime - The highest possible priority. The threads of the process preempt the threads of all of the other processes, including operating system processes that perform important tasks. Note that the user must have proper security permissions to set priority to this level.

Store process identifier in variable

Text

No

(Empty)

RESULTPID="Text"

The name of the variable in which to populate with the global process identifier that can be used to identify a process.

NOTE: The process identifier is valid from the time the process is created until the time the process is terminated.

Computer Properties

Property

Type

Req'd

Default

Markup

Description

Local computer

---

---

---

---

If enabled, specifies that the process to start resides on the local machine. This parameter is enabled by default. If this parameter is selected, the Another Computer parameter becomes inactive. This is a visual mode parameter used during design time only, therefore, it contains no markups.

Another computer

---

---

---

---

If enabled, specifies that the process to start resides on a remote machine. Other parameters become active if this parameter is enabled. If this parameter is selected, the Local Computer parameter becomes inactive. This is a visual mode parameter used during design time only. Therefore, it contains no markups.

Machine Name

Text

Yes

(Empty)

  1. REMOTEMACHINE="pcname.domain.com"

  2. REMOTEMACHINE="xxx.xxx.xxx.xxx"

The host name or IP address of the remote machine where the process to start resides. This parameter is available only if the Another Computer parameter is enabled.

Machine Domain

Text

No

(Empty)

DOMAINNAME="netauto"

The domain name of the remote machine where the process to start resides. This parameter is available only if the Another Computer parameter is enabled.

Username

Text

No

(Empty)

USERNAME="Bruce.Wayne"

A valid user name used to log onto the remote machine in which the process to start resides. This parameter is available only if the Another Computer parameter is enabled.

Password

Text

No

(Empty)

PASSWORD="encrypted"

The password corresponding to the username entered in the Username field. This parameter is available only if the Another Computer parameter is enabled.

Description Properties

The Description tab allows you to customize the text description of any step as it appears in the Task Builder's Steps Pane.

More on setting custom step description

Error Causes Properties

The Error Causes tab properties allows you to instruct a task step to react only to specific errors or ignore certain errors that should cause it to fail.

More on Error Causes properties

On Error Properties

The On Error tab properties lets you determine what the task should do if a particular step encounters an error as defined in the Error Causes properties.

More about On Error properties

Notes

Variables and Expressions

All text fields allow the use of expressions, which can be entered by surrounding the expression in percentage signs (example: %MYVARIABLE%, %Left('Text',2)%). To help construct these expressions, you can open Expression Builder from these fields by pressing F2.

More on variables
More on expressions

More on the expression builder

Example

NOTE: The code below can be copied and pasted directly into the Steps pane of the Task Builder.

 

Description: Start local process "C:\Program Files (x86)\Adobe\Adobe Photoshop CS3\Photoshop.exe". Store process identifier in variable named "TheProcess".

 

<AMPROCESSES ACTIVITY="create" PRIORITY="abovenormal" EXECUTABLE="C:\Program Files (x86)\Adobe\Adobe Photoshop CS3\Photoshop.exe" WORKINGDIR="C:\Program Files (x86)\Adobe\Adobe Photoshop CS3" RESULTPID="TheProcess" />

 

↑ [Top of Page]