0x1 issue in windows task scheduler

خرید بک لینک

I am running a bat file which will delete the files or folders older than 14 days from the today's date , when i am testing it in local folders it is executing fine, but when i am trying to delete the files or folders from the network drive. I am getting error 0x1. Could some one help me out on this. I am trying this from last 2 weeks still didnt find any solution. :(

Also to mention i have tried lot of ways like giving the start in parameter, run with super privileges , run whether the user is logged on or not. All this i have tried but no resolution.

Note: When run when the user is logged in is checked , the task run successfully and i get result 0x0, but i need to run on whether user is logged on or not.

Below is my script if you find any issue or required modification let me know. I am new to this.

%1
%2
%3
%4
forfiles -p %1 -s -m *.* /D -%2 /C "cmd /c del @path"
for /f "delims=" %%d in ('dir %1 /A:D /B /S ^| sort /r') do rd "%%d" 2>NUL >NUL
forfiles -p %3 -s -m *.* /D -%2 /C "cmd /c del @path"
forfiles -p %4 -s -m *.* /D -%2 /C "cmd /c del @path"

%1 - %4 are the parameters i am passing throung the arguments in the task scheduler

Recent Questions...

ما را در سایت Recent Questions دنبال می‌کنید

برچسب: نویسنده: استخدام کار بازدید: 228 تاريخ: دوشنبه 27 ارديبهشت 1395 ساعت: 18:59

صفحه بندی