Tell me more ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

On Windows XP, the total size of Recycle Bin could be seen easily, but I can't see it on Windows 7. Why did Microsoft hide/remove this feature? Am I missing something?

REMARK 1: I don't need to see the maximum size that Recyle Bin can contain.

REMARK 2: Once you have several files selected in the Recycle Bin, you get a "See more details" link in the status bar, but clicking on that does not display the total file size. Microsoft has apparently changed this.

share|improve this question
@Mepher: In short: The total size is listed in the Disk Cleanup. – Tom Wijsman Mar 21 '11 at 1:30

6 Answers

up vote 1 down vote accepted

I ran into this as wel.

The accepted answer didn't satisfy my needs. I wanted to know the size of all the recycle bins as well as the total of these.

Using the WMI provider, it is easy to accomplish this: (save as a .vbs file)

dim oFS, oFolder, fileSizeTotal
Dim objWMIService, objItem, colItems, colPartitions, objPartition, _
    objLogicalDisk, colLogicalDisks
Dim strComputer, strMessage, strPartInfo,strDeviceID,ret
set oFS = WScript.CreateObject("Scripting.FileSystemObject")
Set oShell = CreateObject( "WScript.Shell" )


strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from Win32_DiskDrive")
For Each objItem in colItems
    strDeviceID = Replace(objItem.DeviceID, "\", "\\")
    Set colPartitions = objWMIService.ExecQuery _
        ("ASSOCIATORS OF {Win32_DiskDrive.DeviceID=""" & strDeviceID & _
        """} WHERE AssocClass = Win32_DiskDriveToDiskPartition")
    For Each objPartition In colPartitions
        Set colLogicalDisks = objWMIService.ExecQuery _
            ("ASSOCIATORS OF {Win32_DiskPartition.DeviceID=""" & _
            objPartition.DeviceID & _
            """} WHERE AssocClass = Win32_LogicalDiskToPartition")
        strPartInfo = strPartInfo & "Disk Partition: " & objPartition.DeviceID
        For Each objLogicalDisk In colLogicalDisks
            strPartInfo = strPartInfo & " " & objLogicalDisk.DeviceID
            ret = ret & objLogicalDisk.DeviceID & "\"
            if oFS.FolderExists(objLogicalDisk.DeviceID&"\$Recycle.Bin") then
                RECpath=oShell.ExpandEnvironmentStrings( _
                objLogicalDisk.DeviceID & "\$Recycle.Bin")
                set oFolder = oFS.GetFolder(RECpath)
                ShowFolderDetails(oFolder)
            else
                ret = ret & " -empty- " & vbCr
            end if
        Next
        strPartInfo = strPartInfo & vbCr
    Next
    Wscript.Echo ret & "---------" & vbCr & "Total: " & calcSize(fileSizeTotal)
Next
WSCript.Quit


Sub ShowFolderDetails(oF)
    Dim size
    fileSizeTotal = fileSizeTotal + oF.Size
    size = calcSize(oF.Size)
    ret = ret & " = " & size  & vbCr
end Sub

function calcSize(sizeInB)
    Dim fSize, iKB, iMB, iGB, d
    iKB = 1024
    iMB = iKB * 1024
    iGB = iMB * 1024
    d = 2
    if sizeInB >= iGB then
        fSize = round(sizeInB/iGB,d) & " GB"
    elseif sizeInB >= iMB then
        fSize = round(sizeInB/iMB,d) & " MB"
    elseif sizeInB >= iKB then
        fSize = round(sizeInB/iKB,d) & " KB"
    else
        fSize = sizeInB & " B"
    end if
    calcSize = fSize
end function

or get it from here: http://dl.dropbox.com/u/32933085/RecycleBinInfo.vbs

edit: I updated the script so it will not crash if the partition has no recycle bin. Also Bytes are now shown correctly

share|improve this answer
It works fine. Thanks and accepted! – Mehper C. Palavuzlar Nov 8 '12 at 14:07

Sort the Recycle Bin by Item Type, then select all the files, do not select any directories. At the bottom you will be able to see the size of all the files if you show detailed information.

An alternative way is to select all the hidden system folders called $Recycle.bin in the System Root and viewing the details or properties of your selection, but above method should just do...

DIR /S %SYSTEMDRIVE%\$RECYCLE.BIN | FINDSTR /C:File(s)

See the last entry of above command to get the size of the recycle bin from a command prompt.

I wonder why it's important to know the size of the recycle bin though, when you want to know how much space you earn it's better to use Disk Cleanup or a similar tool, but for just getting rid of your deleted items it is not necessary. I think they left that feature out because it would have to look at different recycle bins, but indeed, with an extra effort it wouldn't be hard to implement...

enter image description here

share|improve this answer
1  
You’ll also want to de-select shortcuts because they too can interfere with the size (sometimes they don’t need to be, sometimes they do; I suspect that it depends on if they are valid). Of course the more items you have in the bin, the longer it takes to show the total size. As for a reason for knowing the size, just because Tom cannot think of one, doesn’t mean the rest of us who want to know shouldn’t. I find this behavior of 7 to be one of the worst parts of the OS. Besides, the solution of de-selecting folders is no good since it does not include them. (And Disk Cleanup is no good.) – Synetech Mar 20 '11 at 21:41
@Synetech: Check your assumptions please: Shortcuts don't interfere because they have a size by itself, they do not refer to the size of the target file. You need to show all the files so that it only excludes the folder itself, use the search option for this. Also, don't complain about not being able to think because you can't think of one either. Why would the size of things that lose their existance soon matter at all? Also, have you checked the second paragraph? DIR /S %SYSTEMDRIVE%\$RECYCLE.BIN | FINDSTR /C:File(s) Disk Cleanup is good, run it in sage mode. – Tom Wijsman Mar 20 '11 at 23:37
I already said that sometimes shortcuts don’t interfere. I have had at least two times when the size was not displayed until I de-selected a shortcut, though it may have been because the bin is so unresponsive and not efficient in 7 compared to XP (it usually takes forever to “read” the files if there are a lot: the grey progress bar in the address bar). I can think of a reason why I want to know how much space is in the bin. You obviously have plenty of space, but those who don’t often look at how much space might be recovered—they are not necessarily about to “lose their existence”. – Synetech Mar 21 '11 at 0:10
Oh, and so what about the second paragraph? That does nothing for items from multiple volumes. You obviously either have only one drive or do things in a generally simple manner if does not occur to you that a user may want to know the total amount of files and folders that are currently deleted across multiple drives (and may or may not be restored). Again, if Disk Cleanup is good enough for you, that’s because you do things in a simple manner. It does nothing for files from an arbitrary folder, the cache from a third-party browser, etc. – Synetech Mar 21 '11 at 0:11
@Synetech: Your first comment describes extremely narrow situations, which doesn't apply to the world-wide audience and really doesn't add value to this discussion: You're talking about shortcuts that you can't describe; about an unresponsive recycle bin due to a bad performing hard drive; recovery of things you intend to delete under the condition of running out of space and not knowing the size of the thing you having recently deleted, it's also pretty unlikely that you would recover the whole recycle bin in that case, so I don't see what problem you have with my first paragraph... – Tom Wijsman Mar 21 '11 at 1:22
show 3 more comments

It was suggested on the Microsoft forums (here and here) that running the Disk Cleanup program will provide the total size of all the files inside the Recycle Bin. There's no direct approach similar to what was implemented previously in Windows XP.

share|improve this answer
I don't want to see the maximum. It's not a solution. Regarding the last paragraph of your answer: Once you have several files selected, you get a "See more details" link in the status bar, but clicking on that does not display the total file size. So this doesn't work either. – Mehper C. Palavuzlar Jul 6 '10 at 15:40
You're right - I apologize. Reading this article (en.wikipedia.org/wiki/Recycle_Bin_(Windows)), it does look like MS has changed things in Windows 7. – Isxek Jul 6 '10 at 16:02
I've revised my answer based on further searching. (I'm not sure if I should have removed my previous answers here, but this should help at least.) – Isxek Jul 6 '10 at 16:33
So your findings show me that Microsoft has done a completely nonsense job removing this feature. I totally agree with the user who wrote the following post in MS Answers: It would have been good if MS would save us people trouble to go to all these lengths and just implement the functionality the XP recycle bin had. How difficult it would be to copy old code into the new version anyways? – Mehper C. Palavuzlar Jul 6 '10 at 16:46

You could use something like Rainmeter, which can display an item on your desktop with the size of the items in the recycle bin, not ideal but its an option.

Hope this helps :)

share|improve this answer

WinDirStat will compute the size of your recycle bin, along with presenting a graphic representation of all the files on your HD and how its space is used. If you're trying to figure out where the space on your drive went it's much better than trying to poke around just using explorer.

share|improve this answer

It would have been good if Microsoft would save us people trouble to go to all these lengths and just implement the functionality the XP recycle bin had. Too bad.

The easiest solution I could find is the following:

  1. In Folder Options, turn on the display of hidden files and folders as well as protected operating system files.
  2. Browse to your C: drive, open the $Recycle.Bin folder, and then right-click and choose properties of the Recycle Bin icon you see.

This will show the total size.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.