SolutionSeeker
SolutionSeeker

Reputation: 11

Navigation powershell script fails when run through task scheduler

I am navigating to url to take screenshot of the web page using powershell. Scripts are running when i am manually doing it from powershell and after creating batch files if i am manually executing. I am trying to automate everyday using task scheduler but script fails there. Tried the below from task scheduler: 1. Tried attaching batch file to Program/script task scheduler. 2. Tried Powershell.exe in Program/script than adding path to Add arguments.

Following Add arguments i tried in task scheduler: -ExecutionPolicy Bypass C:\abc\xyz.ps1 -RunType $true

or just specifying the path C:\abc\xyz.ps1

Upvotes: 0

Views: 330

Answers (1)

Sonny Puijk
Sonny Puijk

Reputation: 114

So you're trying to create a screenshot from powershell in a non-interactive session. That won't work, there's no UI to create a screenshot from.

Upvotes: 1

Related Questions