Showing posts with label scheduled tasks. Show all posts
Showing posts with label scheduled tasks. Show all posts

22 May 2014

Use the output of query and run scheduled tasks from a remote computer in powershell



the output will be formated in a csv format and can be assigned to a variable and interpreded:

$taskQuery = schtasks /Query /S computer_name /TN task_name /V /FO CSV

$taskQuery[1].split(',')[3]  - will output:

"Ready"

12 February 2014

Execute sheduled task on remote computer


verify task status:

schtasks /query /S finly /TN "Delta Group Synchronization"


execuite task:
schtasks /query /S computername /TN "Delta Group Synchronization"