Property Value

An agent should always call NotifyComplete when it has completed its intended task. If an agent runs successfully and calls NotifyComplete, its LastExitReason property will have the value Completed.

If an agent is unable to complete its intended task, it should call Abort. If this method is called by the agent, the LastExitReason will be Aborted and the IsScheduled property for the associated ScheduledTask will be set to false. The agent will not be run again until it is rescheduled by the foreground application.