3.2.4.1.38 TaskArguments (Get) (Opnum 44)

The TaskArguments (Get) method retrieves the TaskArguments property.

 [propget] HRESULT TaskArguments(
   [out, retval] BSTR* task
 );

task: Receives the command-line arguments to pass to the task. The arguments need to be formatted as command-line arguments. PLA MUST provide the following substitution variables that can be included in the arguments string. If there are one or more of these variables included in the task arguments, PLA performs the substitution for the variables when the task is triggered.

Variable

Description

{name}

Name of the alert data collector.

{counter}

The path of the performance counter that crossed the threshold.

{date}

Time that the threshold was crossed.

{threshold}

Value of the threshold.

{value}

Value of the performance counter.

{usertext}

String from TaskUserTextArguments.

{logs}

Space-delimited list of full paths to the current data collector files.

{state}

Indicates if the set is running (1 for running, 0 for stopped).

{key}

Space-delimited list of key values that were specified using IDataCollectorSet::SetValue (to clarify, the SetValue function takes in a Key parameter and a Value parameter, and the list created here contains the Value parameters, not the Key parameters). Each individual value can be any non-empty string.

The values themselves are user-provided and their use is to contain additional data that the user could want stored with the data collector set. The values are not interpreted by PLA and they are stored for the user's convenience.

Return Values: This method MUST return an HRESULT with the severity bit clear on success as specified in [MS-ERREF]; otherwise, it MUST return one of the errors as defined in 2.2.1 or one of the errors as defined in [MS-ERREF] section 2.1.