Page 1 of 1

Scheduling Agent - MaxRunTime & KillAtDurationEnd

Posted: Wed Jul 20, 2011 3:14 am
by jcheng
I want to ask about creating a task with the TTaskItem.MaxRunTime & TTrigger.KillAtDurationEnd properties.


I am trying to control the duration of the task and whether it will kill itself when the duration complete.

But I found that it has no effect no matter I set KillAtDurationEnd to true or false. The check box will still be checked when I see it by scheduler(XP), as shown in the attached GIF.

However, I found that if I set the MaxRunTime to 4294967295. It SEEMS that it would be able to disable the duration-end-killing, because the check box is no longer checked.


So, maybe you can provide me some better information of the behavior between the MaxRunTime, KillAtDurationEnd, the "Stop the task if it runs for X hours Y minutes" checkbox and whether the process really kill/not-kill itself with these settings?

Thank you very much.



(Also sent this as email to your support@sicomponents.com)

Posted: Wed Jul 20, 2011 8:26 am
by isiticov
Hello,

When you set MaxRunTime to 4294967295 (INFINITE) value this indicates to Task Scheduler never kill this task. Other values always indicate to Task Scheduler to kill the task after specified MaxRunTime. Task Scheduler always kills the tasks by default.