Can't delete a folder win 10 [duplicate]

I have a folder on my desktop called con.

15/02/2016  11:29    <DIR>          con

I cannot open it

unopenable folder

I have tried the following

  1. run cmd as administrator
  2. kill explorer.exe
  3. rmdir con

C:\Users\sean\Desktop>rmdir con /s

con, Are you sure (Y/N)? Y

Access is denied.

  1. Set the security settings

security settings

The only option remaining that I have seen is to use a gparted on a linux distribution. However, there must be a way to do it in windows?

Does anyone know why this is happening and how to delete an unopenable and undeletable folder in Winodws 10?


Source: http://answers.microsoft.com/en-us/windows/forum/windows_8-files/a-folder-that-refused-to-be-deleted-invalid-file/a8506e19-d623-4af0-ab19-0fd17a672a3a

Solution quote modified to suit your folder location

Solution You can remove this using the command line, but will want to reference the location differently than you normally would (using UNC).

If the folder is C:\Users\sean\Desktop\con, then this command entered on the command line will remove it:

rd \\.\\c:\Users\sean\Desktop\con /S /Q

rd is the command line tool to remove the directory.

\\. refers to the current computer.

\c:\Users\sean\Desktop\con is the path of the offending folder entry.

/S is a switch that tells rd to remove all subdirectories and files (like the old DELTREE command).

/Q is a switch that tells rd to this removal silently (you won't be prompted for removing the contents).

Change the \c:\Users\sean\Desktop\con path to whatever the location is for your CON folder.

This deletes the entire folder and its contents. It may be possible to rename or copy the folder to another name. I didn't have much luck with the rename, but I also didn't spend too much time on it.

Note that although you can use Windows Explorer to browse to the location \., Explorer doesn't let you delete the folder. You need to use the command line to remove the CON folder.


Try this.

RD /S /Q c:\Users\sean\Desktop\con
  • RD stands for Remove Directory
  • /S deletes all subfolder and files
  • /Q deletes with no more confirmation required