ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

Is there a way or command to delete Recycle Bin and specific folders automatically every 2 days ?

user-image
تم إضافة السؤال من قبل مستخدم محذوف‎
تاريخ النشر: 2014/10/18
Emad Mohammed said abdalla
من قبل Emad Mohammed said abdalla , ERP & IT Software, operation general manager . , AL DOHA Company

I fully agree with MR Darius Thaddeus Meneses  

تابر نجد الدين على سعيد
من قبل تابر نجد الدين على سعيد , Systems Administrator , Wipro Limited - Saudi Arabia

C:\\> recycle.exe /E /FEmptying Recycle Bin: ALL1.save the2 command in file .bat 2. schedule the task to run and specify the numbers of days to run and how many times to run it

Muhammad Anzar
من قبل Muhammad Anzar , DevOps/DevSecOps Architect , Confidential

Yes, its possible through scheduled batch script. You can mention the folder and age for deletion and it will execute every two days from task scheduler. I'm copying helpful content for executing the same

 

REM Remove files older than30 days forfiles /p "C:\\Users\\YOURUSERNAME\\Downloads" /s /m *.* /c "cmd /c Del @path" /d -30

sshot-1

Remember to change the directory to match your computer. You can also choose any directory that is on your computer for the target. Once you have entered the string, save the document as a batch file.

sshot-2

Simply run the file to make sure it works and you will see that any files in your download folder are automatically sent to your Recycle Bin if they are older than30 days.

Create a Scheduled Task

For the purpose of this example, we will schedule the automatic file deletion every seven days. Begin by opening the start menu and typing in “Task Scheduler” then running the application.

Alternatively, you can open your “Control Panel.” Under the “System and Security” section select the “Administrative Tools” option and then run the “Task Scheduler.”

Once you have the program open, click on the “Action” drop-down menu and select “Create Basic Task.”

sshot-3

You can give the task a name and description of your choosing. For this example, we will call it “Weekly Download Cleanup” and leave the description empty since the title is self-explanatory; then click “Next.”

sshot-4

From the “Trigger” section, we will choose to make the task a weekly action followed by pressing “Next.”

sshot-5

Now you will need to select a time and day. Remember to choose a time and day that your computer is powered on. For this example, we will just choose midnight on Friday then click next.

sshot-6

Now you will see the “Action” screen. We will leave this as is, since we want to run a specific program every Friday; so you can just click “Next.”

sshot-7

Now you will just need to click on “Browse” and select the batch file you created. As you can see, our batch file was saved on the desktop and is called “DownloadCleanup.bat.” Once you have done that, just click “Next.”

sshot-8

The last screen you will see gives you a comprehensive overview of the task you created. Once you verify that everything is right, just click “Finish” to complete the task creation and it will run automatically according to your specifications.

sshot-9

Now that you know how to schedule auto-deletion of your old files, you don’t need to worry about how to clear up any old files from your download folder.

مستخدم محذوف‎
من قبل مستخدم محذوف‎

Yes there is a utility called task runner where in you can assign a task along with deatils of time and task to be performed, this utility will be run as per the schedule. For eg:- Many institutes use this utility to run Auto Diskclean, Auto Antivirus Update and Auto Shutdown, etc... you just need to add task through task runner...

Aqeel Jaffer
من قبل Aqeel Jaffer , System & Desktop Engineer , OneVoice Canada

hi,

I think, You do need to write little dos command batch files for your need.

Syed Javed
من قبل Syed Javed , it consultant , Infosys

Use task schedule to delete it automatically per schedule

 

Download CCleaner, its a fast cleaning tool, yo can add it on your taskbar just right click then run ccleaner,

can Also automatically clean your computer every time you start your computer, open CCleaner>Options>Settings,  And Just check "Run CCleaner when computer starts"

 

المزيد من الأسئلة المماثلة

هل تحتاج لمساعدة في كتابة سيرة ذاتية تحتوي على الكلمات الدلالية التي يبحث عنها أصحاب العمل؟