If you are using Outlook, every attachment you have ever opened is still on your hard disk. To see these files, paste this into to the Windows “Run” command box:
%UserProfile%\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Outlook\
What you will see is one or more sub-folders which contain the attachments from previously opened emails. These files take up unnecessary space. They may be a security risk (business or personal), and they may be the thing that saves you when you permanently deleted an email or overwrote the original text of an important document.
In my case, I was interested in selectively recovering drive space when I wrote Manage-OutlookAttachmentFolder.ps1. I used Get-ChildItem (alias GCI to recursively enumerate “$env:UserProfile\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Outlook\”. The size is displayed both as length, and with a calculated column size with MB/GB etc.
The script requires PowerShell 3, as it uses Out-Gridview to display the results. After selecting the files, you can choose to either move them or delete them. I used New-Object System.Windows.Forms.FolderBrowserDialog to choose the destination folder for moves.Script Text