Powershell Task
i using windows 2008r2, created powershell script need run task. created both basic/task , called in .cmd/.bat file, somehow doesn't executes script. if run script command prompt good.
running under domainadmin a/c privileges dont know else wrong?
history of taskscheduler shows no errors!
powershell -nologo -noninteractive -command "& {.\timestamp.ps1}"
if call .bat cmd prompt works!!!
tia
sv
i use
program/script: c:\windows\system32\windowspowershell\v1.0\powershell.exe
arguments: <path>\timestamp.ps1
start in: <path>
so, if timestamp.ps1 oin c:\scripts:
arguments: c:\scripts\timestamp.ps1
start in: c:\scripts\
karl
http://unlockpowershell.wordpress.com
-join("6b61726c6d69747363686b65406d742e6e6574"-split"(?<=\g.{2})",19|%{[char][int]"0x$_"})
Windows Server > Windows PowerShell
Comments
Post a Comment