Batch File running fine if double-clicked but does not run in Windows Scheduled Task

后端 未结 2 480
失恋的感觉
失恋的感觉 2021-01-29 02:15

I have an archive.pst file on my C: drive that I use in outlook to backup my email. But my C: is not backed up each night. So I\'d like to copy the .pst file to my network drive

2条回答
  •  不要未来只要你来
    2021-01-29 03:12

    In reviewing the previous responses, I have shortened the batch file to only the code below. This works when double-clicking, but not when scheduling a task. I've also tried the same task moving the .vbs script to a network drive. Same outcome.

    %SystemRoot%\System32\cscript.exe "C:\OutlookBackup\close_outlook.vbs"
    %SystemRoot%\System32\ping.exe -n 4 127.0.0.1>nul
    %SystemRoot%\System32\cscript.exe "C:\OutlookBackup\open_outlook.vbs"
    

提交回复
热议问题