Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with running PowerShell script as a Schedule Task

Status
Not open for further replies.

TheKidd

IS-IT--Management
May 17, 2000
167
US
Hello all,
I have a quick question. I have a PowerShell script that runs daily at 4AM. Although the job shows completed, it doesn't really run.

The script runs with the following command: powershell.exe -file "path_to_script.ps1"

Any help or suggestions would be greatly appreciated. Thanks.
 
When I edit a task, this is what I have in the Edit Action screen:

Action: Start a program
Program/script:
C:\Windows\SysWOW64\WindowsPowerShell\v1.0\powershell.exe

Add arguments (optional):
C:\path of your scripts\myScript.ps1


 
Thanks ehaze. I'll give that a try.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top