Log Event

Logs an event to the Windows Event Log. Can be used to write an event to the Windows Event Log in order to launch another task set with an Event Log trigger monitoring the specified Event.

To enter Log Event properties:

  1. From the Available Actions pane of the Task Builder, expand the System folder and double-click the 'Log Event' action or drag it onto the Steps pane.

  2. In the Message field, enter the message to be logged. If you want to enter an expression, click the percent sign (%) and use the Expression Builder to create the expression.

  3. Under Message type, select whether the event is to be logged as Information, Warning, or Error.

  4. To set the Description tab properties, please refer to Description Tab Options.

  5. To set the Error Causes and On Error tab properties, please refer to Step Error Handling.

  6. When finished, click OK to save settings and close the properties dialog box.

Declaration

<LOGEVENT MESSAGE="text (message to log)" TYPE="text (options)" />

Example

<LOGEVENT MESSAGE="Be advised - Task C failed." TYPE="error" />

See Also: Change Printer, Empty Recycle Bin, End Process, Get Process Information, Get Volume Information, Log Event, Print, Registry, Run, Set Date and Time

General Tab

Property

Type

Required

Default

Markup

Description

Message

Text

Yes

(Empty)

MESSAGE="Task C failed"

The text message that should be logged.

Message Type

Text (options)

No

Information

TYPE="warning"

How the message should be classified in the Windows Event Log. The available options are:

  • Information: The event will be classified as an informational message.

  • Warning: The event will be classified as a warning.

  • Error: The event will be classified as an error.

See Also

About Actions

Adding Task Steps