Re: Cannot delete folder (directory)

Tech-Archive recommends: Fix windows errors by optimizing your registry



Sorry, I omitted one line from my recipe. It's a line that
distinguishes the Command Prompt from DOS. It's called
"File/Directory completion". The line should be

cmd /f:on
followed by
rd /s /q ^F {Enter}

Since you're so fond of DOS, try some of these very basic
DOS commands in the WinXP Command Prompt:
sys C:
fdisk

They don't seem to work. Now look for the standard DOS
boot files. They have been around since DOS 1.0, without
exception:
c:\msdos.sys
c:\io.sys

Now try some of these Windows command in a real DOS
environment, e.g. after booting the machine with a DOS
boot disk from www.bootdisk.com:

set /p name=Please enter your name:
for /F %a in (c:\boot.ini) do @echo %a

DOS can't to any of this, because it's strictly Windows stuff.
However, you can still call the Command Prompt "DOS" even
though it lacks the very basic elements of DOS. It's your choice.


"Mike Morrow" <MikeMorrow@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:14F18AD4-C7C4-4B52-BEB0-013AFC552F7A@xxxxxxxxxxxxxxxx
Since I have been doing computers for 30 years and actually ran on DOS
before
Windows came along, I still call it DOS. You can call it the Command
Prompt
or the CLI or "cmd" or whatever you want but it is still DOS to me.

I have already tried to remove the directory. I am not so stupid that I
did
not try this already. It does not work.

I don't know what this Ctrl+F business is about. It just puts up ^F as
many
times as I press it. Never heard of this before and, it seems, neither
has
DOS.

Here are the results of my trials and failures to remove this invalid
directory.

L:\rmdir ba*
^
The filename, directory name, or volume label syntax is incorrect.

L:\>rmdir /s back*
back*, Are you sure (Y/N)? y
The filename, directory name, or volume label syntax is incorrect.

L:\>rmdir backup*
The filename, directory name, or volume label syntax is incorrect.

L:\>rm /?
'rm' is not recognized as an internal or external command,
operable program or batch file.

L:\>rmdir /s /q backup

L:\>dir
Volume in drive L is RAID Mirror
Volume Serial Number is 20FB-0B9F

Directory of L:\

05/31/2006 06:16 PM <DIR> AniMusic
03/21/2007 07:01 PM <DIR> Audio Books
03/24/2007 04:07 PM <DIR> Backup
03/23/2007 08:16 PM <DIR> Backup_GOOD
12/10/2005 12:38 PM 43,008 CEU Tapes & Hours Listing.doc
04/28/2005 10:55 PM <DIR> iconmagic
03/23/2007 08:16 PM <DIR> Monthly PHPFiles Backup
10/11/2006 01:23 PM <DIR> NCLEX Install Files
01/13/2006 12:06 AM 43,008 Patient Assessment Work***.doc
06/29/2005 07:15 PM <DIR> PHP Graphics & Web Files
10/19/2006 02:20 PM <DIR> PHP Work Done for Others
01/02/2007 07:25 PM <DIR> Scanned Records & Tracking
02/10/2007 05:41 PM <DIR> School Videos in mp3
03/27/2007 06:25 PM 80 Try.bat
12/09/2005 05:22 PM 68,608 UNIT 4.doc
03/27/2007 06:07 PM <DIR> zPersonal and Historical
4 File(s) 154,704 bytes
12 Dir(s) 64,576,397,312 bytes free

L:\>rmdir /s /q backup
The system cannot find the file specified.

L:\>rmdir /s /q backup
The system cannot find the file specified.

L:\>dir
Volume in drive L is RAID Mirror
Volume Serial Number is 20FB-0B9F

Directory of L:\

05/31/2006 06:16 PM <DIR> AniMusic
03/21/2007 07:01 PM <DIR> Audio Books
03/24/2007 04:07 PM <DIR> Backup
03/23/2007 08:16 PM <DIR> Backup_GOOD
12/10/2005 12:38 PM 43,008 CEU Tapes & Hours Listing.doc
04/28/2005 10:55 PM <DIR> iconmagic
03/23/2007 08:16 PM <DIR> Monthly PHPFiles Backup
10/11/2006 01:23 PM <DIR> NCLEX Install Files
01/13/2006 12:06 AM 43,008 Patient Assessment Work***.doc
06/29/2005 07:15 PM <DIR> PHP Graphics & Web Files
10/19/2006 02:20 PM <DIR> PHP Work Done for Others
01/02/2007 07:25 PM <DIR> Scanned Records & Tracking
02/10/2007 05:41 PM <DIR> School Videos in mp3
03/27/2007 06:25 PM 80 Try.bat
12/09/2005 05:22 PM 68,608 UNIT 4.doc
03/27/2007 06:07 PM <DIR> zPersonal and Historical
4 File(s) 154,704 bytes
12 Dir(s) 64,576,397,312 bytes free

L:\>rmdir "backup "
The system cannot find the file specified.

L:\>rmdir "backup*"
The filename, directory name, or volume label syntax is incorrect.

L:\>rmdir backup*
The filename, directory name, or volume label syntax is incorrect.

L:\>rmdir backup
The system cannot find the file specified.

L:\>dir
Volume in drive L is RAID Mirror
Volume Serial Number is 20FB-0B9F

Directory of L:\

05/31/2006 06:16 PM <DIR> AniMusic
03/21/2007 07:01 PM <DIR> Audio Books
03/24/2007 04:07 PM <DIR> Backup
03/23/2007 08:16 PM <DIR> Backup_GOOD
12/10/2005 12:38 PM 43,008 CEU Tapes & Hours Listing.doc
04/28/2005 10:55 PM <DIR> iconmagic
03/23/2007 08:16 PM <DIR> Monthly PHPFiles Backup
10/11/2006 01:23 PM <DIR> NCLEX Install Files
01/13/2006 12:06 AM 43,008 Patient Assessment Work***.doc
06/29/2005 07:15 PM <DIR> PHP Graphics & Web Files
10/19/2006 02:20 PM <DIR> PHP Work Done for Others
01/02/2007 07:25 PM <DIR> Scanned Records & Tracking
02/10/2007 05:41 PM <DIR> School Videos in mp3
03/27/2007 06:25 PM 80 Try.bat
12/09/2005 05:22 PM 68,608 UNIT 4.doc
03/27/2007 06:07 PM <DIR> zPersonal and Historical
4 File(s) 154,704 bytes
12 Dir(s) 64,576,397,312 bytes free

L:\>rmdir /s backup
backup, Are you sure (Y/N)? y
The system cannot find the file specified.

L:\>dir
Volume in drive L is RAID Mirror
Volume Serial Number is 20FB-0B9F

Directory of L:\

05/31/2006 06:16 PM <DIR> AniMusic
03/21/2007 07:01 PM <DIR> Audio Books
03/24/2007 04:07 PM <DIR> Backup
03/23/2007 08:16 PM <DIR> Backup_GOOD
12/10/2005 12:38 PM 43,008 CEU Tapes & Hours Listing.doc
04/28/2005 10:55 PM <DIR> iconmagic
03/23/2007 08:16 PM <DIR> Monthly PHPFiles Backup
10/11/2006 01:23 PM <DIR> NCLEX Install Files
01/13/2006 12:06 AM 43,008 Patient Assessment Work***.doc
06/29/2005 07:15 PM <DIR> PHP Graphics & Web Files
10/19/2006 02:20 PM <DIR> PHP Work Done for Others
01/02/2007 07:25 PM <DIR> Scanned Records & Tracking
02/10/2007 05:41 PM <DIR> School Videos in mp3
03/27/2007 06:25 PM 80 Try.bat
12/09/2005 05:22 PM 68,608 UNIT 4.doc
03/27/2007 06:07 PM <DIR> zPersonal and Historical
4 File(s) 154,704 bytes
12 Dir(s) 64,576,397,312 bytes free

L:\>rmdir /s "backup "
backup , Are you sure (Y/N)? y
The system cannot find the file specified.

L:\>dir
Volume in drive L is RAID Mirror
Volume Serial Number is 20FB-0B9F

Directory of L:\

05/31/2006 06:16 PM <DIR> AniMusic
03/21/2007 07:01 PM <DIR> Audio Books
03/24/2007 04:07 PM <DIR> Backup
03/23/2007 08:16 PM <DIR> Backup_GOOD
12/10/2005 12:38 PM 43,008 CEU Tapes & Hours Listing.doc
04/28/2005 10:55 PM <DIR> iconmagic
03/23/2007 08:16 PM <DIR> Monthly PHPFiles Backup
10/11/2006 01:23 PM <DIR> NCLEX Install Files
01/13/2006 12:06 AM 43,008 Patient Assessment Work***.doc
06/29/2005 07:15 PM <DIR> PHP Graphics & Web Files
10/19/2006 02:20 PM <DIR> PHP Work Done for Others
01/02/2007 07:25 PM <DIR> Scanned Records & Tracking
02/10/2007 05:41 PM <DIR> School Videos in mp3
03/27/2007 06:25 PM 80 Try.bat
12/09/2005 05:22 PM 68,608 UNIT 4.doc
03/27/2007 06:07 PM <DIR> zPersonal and Historical
4 File(s) 154,704 bytes
12 Dir(s) 64,576,397,312 bytes free

L:\>

"Pegasus (MVP)" wrote:


"Mike Morrow" <MikeMorrow@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:2691B86D-8A7F-4D4C-AD4F-5B515392744B@xxxxxxxxxxxxxxxx
I programmatically created a folder named "Backup ". Yes, an invalid
trailing blank. Trailing periods are removed but not blanks.

Windows uses it just fine placing content inside it. Chkdsk sees no
problem
but I cannot delete the folder. WExplorer says it cannot read from
the
source file or directory. DOS says it cannot find the name. Windows
created
it but then can't handle it in any way.

How do I rename or delete this folder? I can find no way and am not
new
to
this game!

Thanks for any pointers for fixing this M$ bug.

A few observations:
- A space anywhere in file name is not "invalid" - it is perfectly OK.
- DOS is an operating system, same as Linux or Windows.
It does not exist under Windows - you probably mean
the "Command Prompt" when you say "DOS".
- What you observe is not a Windows "bug" but probably
incorrect syntax.

To delete the offending folder, do this:
- Click Start / Run / cmd {OK}
- Type these commands:
cd /d "c:\Documents and Settings\Mike\My Documents"
(type the correct name to the parent of the problem folder)
- Type this command:
rd /s /q ^F {Enter}
(note: ^F stands for Ctrl+F. You must press Ctrl+F as
many times on the keyboard until the offending folder name
appears. Do not press Enter until you see the correct folder
name!)





.


Quantcast