Q. I have a collection of temporary Microsoft Office files that all start with ~. How can I easily delete them?

John Savill

January 9, 2011

1 Min Read
ITPro Today logo in a gray background | ITPro Today

A. Each time you don't cleanly close an Office document you'll get one or more temporary files left behind that start with the tilde (~) character. An easy way to see them all is to open a command prompt then run

dir /ah /s d:documents~*.*

The /ah tells the system to look for hidden files and /s tells it to search sub folders. d:documents is my root folder for documents, but yours will likely be different. To delete them, just replace dir with del.

D:Documents>del /ah /s ~*.*
 Deleted file - D:DocumentsArticlesWindowsITPro~$curity Special 2010.doc
 Deleted file - D:DocumentsArticlesWindowsITPro~WRL0003.tmp
 Deleted file - D:DocumentsArticlesWindowsITPro~WRL0856.tmp
 Deleted file - D:DocumentsArticlesWindowsITProVDI Part 2~$I Part 2.docx
 Deleted file - D:DocumentsArticlesWindowsITProVDI Part 2~WRL0003.tmp
 Deleted file - D:DocumentsArticlesWindowsITProWindows 2008 R2 SP1~$ndows 20
 08 R2 SP1.docx
 ...
 Deleted file - D:DocumentsTemplate objects~$TechEd_image_resource_partA.pptx
 Deleted file - D:DocumentsTemplate objects~$Virtualization objects.pptx

Read more about:

Microsoft

About the Author

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like