Hi,
I want to run a script via scheduled task. It runs fine when ran in Powershell (ISE).
When ran in scheduled task, it pops up a Powershell but then directly stops. No output at all. Have inserted a try catch which would send an email with error (which works fine when not launched in scheduled task) but no email.
Have scheduled a similar script with same settings (same user, same priviliges, same trigger) and that runs fine.
My script also runs fine when I copy paste what's in the scheduled taks = powershell.exe -file 'E:\Scripts\MyScript.ps1'
Please advise howto troubleshoot.
J.
Jan Hoedt