Remove directory with reserved characters

C

Christoph

I have two directories that I can't remove for the life of me.
One has a directory name that includes two trailing dots

"My Dir.."

and the other has a directory name that includes a space

"My Dir "

And neither of which I am able to remove. Each time I try
I get the error message:

"The system cannot find the file specified."

I've gone to the KB and did extensive searching on how to
remove these directories, but nothing recommended there
(including suggestions on this page:
http://support.microsoft.com/default.aspx?scid=kb;en-us;320081)
has worked. Is there a utility that I can use that will force
the removal of these directories? I'd rather not format my
drive if at all possible because that will require a reinstall of
my OS...

thnx,
Christoph
 
C

Christoph

Did you try "My Dir*"?

c:\>rd "My Dir*"
The system cannot find the file specified.
"C:\My Dir .."

I can keep moving the * to the left one character
but each time, the error is the same.

thnx,
Christoph
 
J

Jim Byrd

Hi Christoph - Sometimes you will find files which you're unable to delete
because they are in use, or, as in your case, have malformed names. Delete
Invalid File, below, is the one that I would expect will fix your issue, but
give the others a try also.


A program called Copylock, here,
http://noeld.com/programs.asp?cat=misc#CopyLock can aid in the process of
"replacing, moving, renaming or deleting one or many files which are
currently in use (e.g. system files like comctl32.dll, or virus/trojan
files.)"

Another is Killbox, here: http://www.downloads.subratam.org/KillBox.zip

A third which is a bit different but often useful is Delete Invalid File,
here: http://www.purgeie.com/delinv.htm which handles invalid/UNC
file/folder name deleting, rather than the in use problem.

--
Please respond in the same thread.
Regards, Jim Byrd, MS-MVP



In
 
C

Christoph

Did you try "My Dir*"?
Why are you trying in DOS instead of Windows?

How else can I try "My Dir*"? Using the 'Run' command?
It shells out to DOS, too, when typing 'DEL "My Dir*"'...

thnx,
Christoph
 
C

Christoph

Hi Christoph - Sometimes you will find files which you're unable to delete
because they are in use, or, as in your case, have malformed names. Delete
Invalid File, below, is the one that I would expect will fix your issue, but
give the others a try also.

That worked like a charm! Thank you soooo very much! :)

thnx,
Christoph
 
J

Jim Byrd

YW, Christoph - Glad it worked for you.

--
Please respond in the same thread.
Regards, Jim Byrd, MS-MVP



In
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top