Quantcast
Channel: PowerShell General
Viewing all articles
Browse latest Browse all 10624

Including Task result in the output

$
0
0

Normal 0 false false false EN-IE X-NONE X-NONE

Hi All,

 I am running this script on a daily basis and getting the correct output.

 

Is there any way of getting the below script to include the task category in the output.

Normal 0 false false false EN-IE X-NONE X-NONE

 $schedule = new-object -com("Schedule.Service")
$schedule.connect()
$tasks = $schedule.getfolder("\").gettasks(0)
$tasks  | Format-Table  Name,Enabled,NextRunTime,LastRunTime,LastTaskResult

 

 


Viewing all articles
Browse latest Browse all 10624

Trending Articles