Before executing a workflow, ensure that you have associated the workflow to the devices. To execute a worklow
How can I run a powershell script using Execute Windows Script task in Workflow?
Set objShell = CreateObject("Wscript.Shell")
objShell.Run("powershell.exe -noexit c:\scripts\test.ps1")