How To Determine Last Time Scheduled Task Run

Locked
COBS Tech Support
Site Admin
Posts: 101
Joined: Sat May 15, 2021 9:57 am

How To Determine Last Time Scheduled Task Run

Post by COBS Tech Support »

The following script returns the last date and time that CAPITAL Server Agent ran, or attempted to run, a scheduled task:

Code: Select all

Declare dLastDate Type Date
Declare cLastTime Type String
Declare cINI      Type String

cINI := PathData() + "SCHEDULE\AGENT.INI"

dLastDate := CTOD(ReadINI("Scheduler", "LastTaskCheckDate", cINI))
cLastTime := ReadINI("Scheduler", "LastTaskCheckTime", cINI)

Echo(dLastDate)
Echo(cLastTime)
Locked