PyIScheduledWorkItem Object
Python object that encapsulates the IScheduledWorkItem interface
Methods
- CreateTrigger
 
- Creates a new trigger for a task, returns index and new ITaskTrigger interface 
- DeleteTrigger
 
- Deletes specified trigger 
- GetTriggerCount
 
- Returns number of triggers defined for the task 
- GetTrigger
 
- Retrieves ITaskTrigger interface for specified trigger index 
- GetTriggerString
 
- Creates a human-readable summary of specified trigger 
- GetRunTimes
 
- Return specified number of run times within given time frame 
- GetNextRunTime
 
- Returns next time that task is scheduled to run 
- SetIdleWait
 
- Sets idle parms for task with trigger of type TASK_EVENT_TRIGGER_ON_IDLE 
- GetIdleWait
 
- Gets idle parms for task with trigger of type TASK_EVENT_TRIGGER_ON_IDLE 
- Run
 
- Starts task 
- Terminate
 
- Terminate process if task is running 
- EditWorkItem
 
- Brings up standard Scheduled Task dialog 
- GetMostRecentRunTime
 
- Returns last time task ran 
- GetStatus
 
- Returns status (SCHED_S_TASK... constants) 
- GetExitCode
 
- Returns tuple of task's exit code and error returned to Task Scheduler if process could 
not start 
- SetComment
 
- Set comment string for task 
- GetComment
 
- Return comment string associated with task. 
- SetCreator
 
- Specify who (or what) created task, can be any string 
- GetCreator
 
- Returns creator info, can be any string data 
- SetWorkItemData
 
- Set data associated with task (treated as uninterpreted bytes) 
- GetWorkItemData
 
- Retrieve data associated with task 
- SetErrorRetryCount
 
- Specify nbr of times to attempt to run task if it can't start (not currently 
implemented) 
- GetErrorRetryCount
 
- Return nbr of times Task scheduler should try to run task (not currently 
implemented) 
- SetErrorRetryInterval
 
- Interval in minutes between attempts to run task. Not implemented according 
to SDK 
- GetErrorRetryInterval
 
- Returns nbr of minutes between attempts to run task. Not implemented 
according to SDK 
- SetFlags
 
- Set flags for task 
- GetFlags
 
- Returns flags for task (TASK_FLAG_* constants) 
- SetAccountInformation
 
- Set username and password under which task will run 
- GetAccountInformation
 
- Returns username that task will run under