How do I open a recycled file from cmd?

by Mark Dodsons   Last Updated January 13, 2018 17:01 PM

if you DIR /a /b /s C:\$Recycle.Bin You will find some regular files, and some that have been turned into "info files" that look like $RT58F.png. If you go into the explorer they are shown as their previous versions, but if you click on it, it gives you the option to "restore" it. I'm wondering if it is possible to display this file's restore option from the CMD? I've tried starting it, and I've tried using explorer /select,Filename. I'm out of ideas.

EDIT: I'm not sure whether this should be here or on StackOverflow. This is more of a systematic thing than a coding thing so I feel it should be here. Let me know!



Answers 1


The Recycle Bin in Windows is a special folder and as such, restoring files from the command prompt is not possible.

It may be possible to copy the file manually to a place outside of the recycle bin though. The folder has more info on each file, for example, their full name and their original location.

In any case, you can try the command start filename.ext but if that doesn't work, try copying the file to a folder outside of the $Recycle.bin folder, such as c:\temp and try to open it from there.

LPChip
LPChip
January 13, 2018 16:46 PM

Related Questions




Recycling bin access denied on windows 10

Updated December 24, 2015 11:00 AM

Empty the recycle bin from the command prompt

Updated May 22, 2017 16:01 PM