using DOS to delete a folder

November 12, 2005 at 18:08:52
Specs: Windows ME, 320 MB

I am trying to force a folder to delete. Here's the story:

I was copying a folder with music in it from one directory to another. And from time to time, when I do this, my PC will freeze. This time, it froze and the contents inside the folder were all jumbled up. the filenames and contents of the actual songs is beyond repair. So I'm looking to just delete the folder, re-rip the CD and be on my merry little way.

So what I'm asking is:
How do you delete a directory in DOS. By the way, when I open the DOS prompt, I'm stuck on the C: drive. How do I get to the H: drive (where my music is kept)? All help is greatly appreciated.

Thank you for your time,
Ryan.


See More: using DOS to delete a folder

Report •


#1
November 12, 2005 at 19:31:00

DOS commands are covered here

To navigate to another drive, merely enter it - in this case

H:

To remove a directory in DOS, couple of ways, but the simplest would be deltree

deltree H:\yourfolder


That should remove the directory and its contents, including any subfolders - be careful, as files deleted this way bypass the recycle bin. You'll be asked to confirm the deletion

Resist the temptation to close your request for help with semantically-null questions like “Can anyone help me?”


Report •

#2
November 12, 2005 at 21:38:18

I get an error message:
Error Deleting File or Folder

And it says:
Cannot delete file: Windows is unable to find the file. This item might have already been deleted or moved. Press F5 to refresh the view of this folder.


Report •

#3
November 12, 2005 at 22:26:50

Ok - well you might try deleting with Windows from Safe Mode, or else from a DOS boot (using a diskette)

Resist the temptation to close your request for help with semantically-null questions like “Can anyone help me?”


Report •

Related Solutions

#4
November 12, 2005 at 22:33:36

Also... if the folder has a long filename (greater than 8 characters) or contains spaces, DOS may require you to enclose the name in "quotes" - for example

deltree "H:\my favourite music files"

Resist the temptation to close your request for help with semantically-null questions like “Can anyone help me?”


Report •

#5
November 13, 2005 at 03:07:45

The failure to delete would indicate a scrambled disk structure.

A forceful delte can make it worse.

First run scandisk or chkdsk.

Then proceed as per jboy.


If at first you don't succeed, you're about average.

M2


Report •

#6
November 13, 2005 at 16:08:39

For sure, I should have suggested that (what was I thinking?)

Possibly you can just delete it, but in all likelihood there are logical drive errors that will need to be corrected

Resist the temptation to close your request for help with semantically-null questions like “Can anyone help me?”


Report •


Ask Question