Scheduled task script won’t run a cmdlet

Hi, I’m very new into the world of scripting and programming in general.

I need to create a script that displays a message if certain Windows configuration is not as expected. I have done most of the script, but it fails when it’s run as a scheduled task. The part that runs the message is this:

 Start-Process "warning.bat" 

As you can see it’s a .bat file. If I execute the .ps1 manually it displays the warning, but not if the script runs as a scheduled task

Any idea?

submitted by /u/IntentoDeAstronauta
[link] [comments]

Leave a Reply