Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

Error in copying the files via Task-scheduler by running Powershell script

$
0
0

Hi Guys,

I am trying to copy files from a Network location to a local folder using Powershell scripting. The very strange thing is, when I run this script via Powershell ISE it working fine. But when i run this script via Windows Task Scheduler from the same machine, it is unable to copy files. It is even unable to see the files in the network drive.

Eg: when i run this command via Windows Task-scheduler, i.e. $(ls $(Network_Location_Name) | Measure-Object -Property Length -Sum).Count | outfile FileName.log, the result is ZERO !

Please help and thanks in advance! 

Regards

Mike


Mike


Viewing all articles
Browse latest Browse all 15028

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>