PdcSchedulerTasks.Active

From External Bemet Wiki
Revision as of 13:53, 24 November 2015 by TC (talk | contribs) (Created page with "== Declaration == Active as PdcSchedulerTask == Description == == Notes == This property retrieves the active task when a script is started from the scheduler.<BR> A sc...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Declaration

Active as PdcSchedulerTask

Description

Notes

This property retrieves the active task when a script is started from the scheduler.
A script can get some properties with data of the active task.

Code example

This code example opens a schedule with ID 1 and returns its schedule name in a msgbox.

sStartMain

Sub sStartMain
dim objTask
dim strlstText

  set strlstText = TStringList.Create
  set objTask = pdc.SchedulerTasks.Active
  if isvalid(objTask) then
    strlstText.Add "An active determined"
    strlstText.Add objTask.Text
  else
    strlstText.Add "No active task"
  end if
  strlstText.SaveToFile "C:\Temp\TestTask.txt"
  strlstText.Free
End Sub

Availability

Available since November 2015 (from version 5.0).