Can't delete file (possibly name too long)

A

Andy Harris

I am running Windows 2000 and I have a jpg file which the
system will not let me delete. I think that it is a
possibility that the file name is too long.
I was in the process of trying to delete some old
directories and I got an error message stating that it
file *.jpg (the actual file name is a very long title for
the photo) because the file did not exist. However, if you
go into the directory where the file is, you can see the
file (in Windows Explorer). If you try to carry out any
functions on the file (copy, delete, rename, etc.) it does
nothing (no error message, nothing, it just seems to
ignore the command).
If you go to the folder for that directory and try to
delete the folder you get the "file *.jg does not exist"
error message and it will not delete the directory.
The file name is an extremely long name (I have not
counted the exact number of characters) so I am wondering
it perhaps the name is invalid.
Anyone have any suggestions as to how I can delete the
file?
(I have tried going to a command prompt and still cannot
delete the file there either).
 
G

Guest

Did you try to end the proces from the task manager? What
name does the file have from the command prompt? You may
have to delete it from the command prompt before Windows
loads.
 
G

Guest

Theres no process to end in task manager as nothing is
hanging up.
The file name at command prompt is the first few letters
of the file name followed by ~ (just like DOS shows file
names longer that 8.3).
 
R

R. C. White

Hi, Anonymous.

Can you isolate the unwanted file in a folder by itself - and then remove
the folder? You may need to move all the other files and subfolders out of
this folder, since you can't move this file. Once you've removed everything
you want to keep from that folder, then, at a command prompt, type: rd
<folder> /s

The /s switch removes the named folder, plus all subfolders and files within
it - without asking their names.

RC
 
G

Guest

I had the exact same problem and this solution worked for
me. Thanks for your help.
 
L

Lamar

I had the identical problem and this solution worked for
me. Thanks for your help.
 

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