How to empty the Windows Recycle Bin automatically
#1
Lightbulb 
Quote:
[Image: powershell-delete-recycle-bin-files.png]

All files that you delete regularly on Windows are moved to the Recycle Bin first. Designed as a last resort to recover accidentally deleted files, files that sit in the Recycle Bin may sit there for a long period. While that is not a huge problem most of the time, if disk space is scarce, it may be frustrating to empty the Recycle Bin manually regularly.

You could set a custom Recycle Bin size to avoid it occupying too much space on a drive, or, use automation to clear the Windows Recycle Bin regularly.

This guide offers a general solution to the Recycle Bin problem, and a specific solution that is only available on Windows 10 devices.

General Solution for all Windows versions

The following method is compatible with all Windows versions and editions. It requires the creation of a batch file and running that batch file either using a policy or as a startup command.

1. Right-click on the desktop or another folder and select New > Text Document.
2. Paste the following line of code into the document: PowerShell.exe -NoProfile -Command Clear-RecycleBin -Confirm:$false
3. Save the document.
4. Rename it to emptyrecyclebin.bat. Make sure the file has the .bat extension and not .bat.txt.
5. Test the file once to make sure it works.
Continue Reading
[-] The following 3 users say Thank You to harlan4096 for this post:
  • Deep900, dinosaur07, silversurfer
Reply


Messages In This Thread
How to empty the Windows Recycle Bin automatically - by harlan4096 - 12 April 19, 07:11

Forum Jump:


Users browsing this thread: 1 Guest(s)
[-]
Welcome
You have to register before you can post on our site.

Username/Email:


Password:





[-]
Recent Posts
K-Lite Codec Pack 19.6.0 / 19.6.5 Update
Changes in 19.6.5 ...harlan4096 — 07:54
Hardware Monitor 1.63
Hardware Monitor 1...harlan4096 — 07:53
Adobe Acrobat Reader DC 26.001.21367
Adobe Acrobat Read...harlan4096 — 07:50
QOwnNotes
26.4.2  Improved ...Kool — 06:42
Privazer 4.0.120.2
Privazer 4.0.120.2...harlan4096 — 07:30

[-]
Birthdays
Today's Birthdays
avatar (43)Sanfordbup
avatar (38)Der.Reisende
Upcoming Birthdays
avatar (45)wapedDow
avatar (49)oapedDow
avatar (42)Sanchowogy
avatar (46)MeighGoask
avatar (47)creatralGuelm
avatar (38)procnipsut
avatar (44)accenwibly
avatar (41)ahyvily
avatar (38)urumahiz
avatar (44)techlignub
avatar (43)Stevenmam
avatar (50)onlinbah
avatar (50)fuspeukChark
avatar (44)werriewWaiNg
avatar (38)Freemanleo
avatar (43)cdoubapKit
avatar (38)lystraPonia
avatar (31)smith8395john
avatar (51)steakelask
avatar (45)Termoplenka
avatar (43)bycoPaist
avatar (49)pieloKat
avatar (43)ilyagNeexy
avatar (51)donitascene
avatar (51)burntLaw
avatar (41)MrDoorsskibheeds
avatar (51)Toligo
avatar (46)Rodneykak
avatar (49)tradeSmode
avatar (39)vemedProkbior
avatar (38)RobertUtelt
avatar (46)JamesZic
avatar (36)Kiran78

[-]
Online Staff
There are no staff members currently online.

>