Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Remove directory Issues

27 Nov 2010   #1
Tuck

Windows 7 Professional x32
 
 
Remove directory Issues

Hi,

I'm recovering from a nasty hard drive crash and I need to delete some corrupted directories. I'm encountering a problem when using Rmdir(rd) on a specific folder. In an elevated command prompt I type,

RD /S /Q "G:\Folder\Folder\TargetDirectory"

but even with the /s switch I still get the "The directory is not empty." message for each subfolder within the directory. I have also tried shift+delete and deleting in safe mode to no avail. Thanks for any response.

-Tuck


My System SpecsSystem Spec
.
27 Nov 2010   #2
Brink

64-bit Windows 10 Pro
 
 

Hello Tuck,

You might see if you may be able to delete the folder using a command prompt at boot instead.

Folder - Delete from Command Prompt

Hope this helps,
Shawn
My System SpecsSystem Spec
27 Nov 2010   #3
Tuck

Windows 7 Professional x32
 
 

Thanks for the quick response,

I tried deleting from the safe mode command prompt, but I encountered a similar problem. The command prompt listed each subfolder and for each it said "The directory is not empty," except for the last one where it said "The request could not be completed because of an IO error."

-Tuck
My System SpecsSystem Spec
.

27 Nov 2010   #4
Brink

64-bit Windows 10 Pro
 
 

Safe Mode is not at boot. Give it a try it from a command prompt (click on link) opened using your retail Windows 7 installation DVD instead.
My System SpecsSystem Spec
27 Nov 2010   #5
Tuck

Windows 7 Professional x32
 
 

I booted from the install disc and entered the command prompt. Upon trying to change to the drive with the undesired directory in it, by typing "G:", I received the message "the system cannot find the drive specified." The drive is external, which I should have mentioned before, but I don't know if that would make a difference.

Thanks,
Tucker
My System SpecsSystem Spec
27 Nov 2010   #6
Brink

64-bit Windows 10 Pro
 
 

Ah, I see.

See if you may be able to manually delete the contents of each subfolder in the TargetDirectory, then see if you may be able to delete the TargetDirectory.
My System SpecsSystem Spec
27 Nov 2010   #7
Ztruker

Windows 10 Pro X64
 
 

You can also try running chkdsk g: /f against that drive to see if it fixes any file system errors.
My System SpecsSystem Spec
27 Nov 2010   #8
mjf

Windows 7x64 Home Premium SP1
 
 

Quote   Quote: Originally Posted by Tuck View Post
I booted from the install disc and entered the command prompt. Upon trying to change to the drive with the undesired directory in it, by typing "G:", I received the message "the system cannot find the drive specified." The drive is external, which I should have mentioned before, but I don't know if that would make a difference.

Thanks,
Tucker
You are aware that drive letters "change" when booting from system repair or install disk?
My System SpecsSystem Spec
27 Nov 2010   #9
Tuck

Windows 7 Professional x32
 
 

In response to Brink: If I try to open the subfolders, explorer freezes up for ten minutes or so and then displays the message "You need to format the disk G: before you can use it. Would you like to format it?" If I try to delete the subfolders themselves, even outside of the command prompt, I still get the "This directory is not empty," message.

In response to Ztruker: I have tried running chkdsk /f /r, which hangs in step 2 while discovering indexes.

In response to mjf: I do not understand what you mean. I noticed that the command prompt started in the X: drive, but I could switch to my C: drive with no issue. Would other drives letter's change?

Thanks to everybody for their suggestions,
Tuck
My System SpecsSystem Spec
27 Nov 2010   #10
mjf

Windows 7x64 Home Premium SP1
 
 

I thought earlier Brink was talking about booting from your install DVD or System Repair DVD. Then you get an X: prompt.
Windows is not being booted by your HDD. It's using the Winre version of windows on your boot disk.
Most of the drive letters will not coincide with what they are normally when you do a normal boot. In your case C: appears to coincide.

At the X:\...\ prompt
type
>diskpart
>list volume
then you get a list of drive letters next to the label descriptions. Your external (G:will probably have another letter assigned. This is the letter you use until you eventually reboot back into normal Windows 7.
> exit
get you back to
X:\....\
My System SpecsSystem Spec
Reply

 Remove directory Issues




Thread Tools




Similar help and support threads
Thread Forum
Cannot change directory (CD) to a directory with space in the name
Following the directions outlined in https://www.sevenforums.com/general-discussion/144154-change-directory-command-prompt.html including enabling command extensions outlined in https://www.sevenforums.com/general-discussion/41993-command-line.html does not permit the CD command to change the...
General Discussion
Program Files directory renamed itself, among other related issues
I'm having several issues; I've thoroughly messed up my computer in the span of the past hour. I'll try to explain as quickly as possible. I'm on Windows 7 Pro 64-bit, and I have an SSD boot device with all of my files on a HDD. I edited the registry keys forever ago to move my program files...
General Discussion
Replace files in multiple directory, from a single directory
I have a 10 files that have all been categorised into about 40 folders. These files have been damaged. I have a backup of all these files, but they are not categorised and sit in a single directory. Does anyone know of an easy technique to batch replace the damaged files with the originals? ...
General Discussion
possible to entirely remove all permission issues?
One thingthats just killing me with W7 is the rights issues. I supposedly have full admin rights and this is my home PC and the only other account is guest. I have run that reg file that gives you the take control option on the right click menu. But there is just no end to prompts telling me i...
General Discussion
Remove folder from desktop background directory
I right-clicked a JPG photo file and then accidently selected "Set as desktop background". The entire folder containing many other pics was also moved to the "Desktop Background Directory" and I can't delete the pic files or the folder. Is it possible to remove this unwanted folder from the...
General Discussion
How-To: Remove Bonjour and fix networking issues
I just went crazy as how strange issues my computer produced after I installed a program that uses Bonjour service by Apple (usually Adobe CS3 or iTunes). I tried to remove it following the posts I found around the net, but it just totally broke my system. So after a reinstall and some struggle I...
Network & Sharing


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 00:21.
Twitter Facebook Google+ Seven Forums iOS App Seven Forums Android App