IExecAction interface (taskschd.h)

Represents an action that executes a command-line operation.

Inheritance

The IExecAction interface inherits from the IAction interface.

Methods

The IExecAction interface has these methods.

 
IExecAction::get_Arguments

Gets or sets the arguments associated with the command-line operation. (Get)
IExecAction::get_Path

Gets or sets the path to an executable file. (Get)
IExecAction::get_WorkingDirectory

Gets or sets the directory that contains either the executable file or the files that are used by the executable file. (Get)
IExecAction::put_Arguments

Gets or sets the arguments associated with the command-line operation. (Put)
IExecAction::put_Path

Gets or sets the path to an executable file. (Put)
IExecAction::put_WorkingDirectory

Gets or sets the directory that contains either the executable file or the files that are used by the executable file. (Put)

Remarks

This action performs a command-line operation. For example, the action could run a script or launch an executable.

When reading or writing XML, an execution action is specified in the Exec element of the Task Scheduler schema.

If environment variables are used in the Path, Arguments, or WorkingDirectory properties, then the values of the environment variables are cached and used when the Taskeng.exe (the task engine) is launched. Changes to the environment variables that occur after the task engine is launched will not be used by the task engine.

Examples

For more information and example code for this interface, see Time Trigger Example (C++).

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 [desktop apps only]
Target Platform Windows
Header taskschd.h

See also

IAction

Task Scheduler

Task Scheduler Interfaces