ITriggerCollection interface

Provides the methods that are used to add to, remove from, and get the triggers of a task.

Methods

The ITriggerCollection interface has these methods.

Method Description
ITriggerCollection::Clear Clears all triggers from the collection.
ITriggerCollection::Create Creates a new trigger for the task.
ITriggerCollection::get__NewEnum Gets the collection enumerator for the trigger collection.
ITriggerCollection::get_Count Gets the number of triggers in the collection.
ITriggerCollection::get_Item Gets the specified trigger from the collection.
ITriggerCollection::Remove Removes the specified trigger from the collection of triggers used by the task.

Remarks

When reading or writing XML for a task, the triggers for the task are specified in the Triggers element of the Task Scheduler schema.

Examples

For more information and example code for this interface, see Time Trigger Example (C++), Event Trigger Example (C++), Daily Trigger Example (C++), Registration Trigger Example (C++), Weekly Trigger Example (C++), Logon Trigger Example (C++), or Boot Trigger Example (C++).

Requirements

   
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

ITrigger

Task Scheduler Interfaces