Unable to delete folder with too long name



Dear Sir,

Eclipse has created folder inside folder recusively. Now I am not able to
delete this folder using neither 'Windows Explorer' nor using command prompt
using RMDIR/S.
It tells names of folder is too long.

Pleasew help me in how to delete it.


R. C. White

Hi, Sunil.

Even though we don't usually see it, each file/folder with a Long File Name
(LFN) also has a computer-created Short File Name (SFN), also referred to as
an 8.3 filename, since it is limited to 8 characters plus and optional
extension of up to 3 characters. (This goes back in computer history to
MS-DOS and before.)

To see the 8.3 filename of your folder, open a Command Prompt and enter:
Dir /x

That command should present the usual listing of all the files and folders
in that directory, as with the plain Dir command. But the /x switch will
create an additional column, before the LFN, showing the SFN for any file or
folder whose LFN does not also meet the 8.3 requirements. Perhaps there is
a space or other "illegal" character in the filename. The SFN for a LFN
will probably have 6 characters, followed by ~1, or some other digit.

Use the Del or RD command with that SFN to delete your file or remove your
folder. Using RD <SFN> /s for the top-level folder should remove that whole
directory tree.

(As always in a Command Prompt window, type the name of any command followed
by /? to see all the switches and parameters available with that command,
such as: Dir /? )

R. C. White, CPA
San Marcos, TX
(e-mail address removed)
Microsoft Windows MVP
Windows Live Mail 2009 (14.0.8089.0726) in Win7 Ultimate x64
Aug 15, 2014
Reaction score

Paid for software so therefore Spam - bye bye :) - FBS is the most appropriate program to sort out such issues


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