Platform SDK: Task Scheduler

TASK_TRIGGER_TYPE

The TASK_TRIGGER_TYPE enumerated type defines the types of triggers associated with the task. It is used in the TriggerType member of the TASK_TRIGGER structure.

typedef enum _TASK_TRIGGER_TYPE {
  TASK_TIME_TRIGGER_ONCE            = 0,
  TASK_TIME_TRIGGER_DAILY           = 1,
  TASK_TIME_TRIGGER_WEEKLY          = 2,
  TASK_TIME_TRIGGER_MONTHLYDATE     = 3,
  TASK_TIME_TRIGGER_MONTHLYDOW      = 4,
  TASK_EVENT_TRIGGER_ON_IDLE        = 5,
  TASK_EVENT_TRIGGER_AT_SYSTEMSTART = 6,
  TASK_EVENT_TRIGGER_AT_LOGON       = 7
} TASK_TRIGGER_TYPE, *PTASK_TRIGGER_TYPE;

Members

TASK_TIME_TRIGGER_ONCE
Trigger is set to run the task a single time.

When this value is specified, the Type member of the TASK_TRIGGER structure is ignored.

TASK_TIME_TRIGGER_DAILY
Trigger is set to run the task on a daily interval.

When this value is specified, the DAILY member of the TRIGGER_TYPE_UNION structure is used.

TASK_TIME_TRIGGER_WEEKLY
Trigger is set to run the work item on specific days of a specific week of a specific month.

When this value is specified, the WEEKLY member of the TRIGGER_TYPE_UNION structure is used.

TASK_TIME_TRIGGER_MONTHLYDATE
Trigger is set to run the task on a specific day(s) of the month.

When this value is specified, the MONTHLYDATE member of the TRIGGER_TYPE_UNION structure is used.

TASK_TIME_TRIGGER_MONTHLYDOW
Trigger is set to run the task on specific days, weeks, and months.

When this value is specified, the MONTHLYDOW member of the TRIGGER_TYPE_UNION structure is used.

TASK_EVENT_TRIGGER_ON_IDLE
Trigger is set to run the task if the system remains idle for the amount of time specified by the idle wait time of the task.

When this value is specified, the wStartHour, wStartMinute, and Type member of the TASK_TRIGGER structure are ignored.

TASK_EVENT_TRIGGER_AT_SYSTEMSTART
Trigger is set to run the task at system startup.

When this value is specified, the Type member of the TASK_TRIGGER structure is ignored.

TASK_EVENT_TRIGGER_AT_LOGON
Trigger is set to run the task when a user logs on.

When this value is specified, the Type member of the TASK_TRIGGER structure is ignored.

Requirements

  Windows NT/2000: Requires Windows 2000 (or Windows NT 4.0 with Internet Explorer 4.0 or later).
  Windows 95/98: Requires Windows 98 (or Windows 95 with Internet Explorer 4.0 or later).
  Header: Declared in mstask.h.
  Unicode: Defined only as Unicode.

See Also

IScheduledWorkItem::SetIdleWait, TASK_TRIGGER, TRIGGER_TYPE_UNION