Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Problem with del...

1 view
Skip to first unread message

Otto J. Makela

unread,
Dec 14, 1990, 10:57:10 AM12/14/90
to
In article <40...@uniol.UUCP> Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
I got a problem with the 'del'-command.
I've got a certain file, which I can normally list with 'dir',
but which, if I want to rename it, copy it or delete it cannot be
modified. DOS says: "Cannot find file"

First, run CHKDSK on the disk. All OK ?
Certain messed-up directories could cause this.

First I thought of having the READ-ONLY bit set (in which case you could
do ATTRIB -R FILENAME.EXT), but a read-only file can be renamed or copied.
Perhaps some other weird combination of status bits could cause this ?

Also, have you added device drivers into your system ? If the name of the
file is the same as an installable device driver, DOS will attempt to call
the device driver when you try to access the file. This, however, normally
produces an "Access denied" message, not "Cannot find file".
--
/* * * Otto J. Makela <ot...@jyu.fi> * * * * * * * * * * * * * * * * * * */
/* Phone: +358 41 613 847, BBS: +358 41 211 562 (CCITT, Bell 24/12/300) */
/* Mail: Kauppakatu 1 B 18, SF-40100 Jyvaskyla, Finland, EUROPE */
/* * * Computers Rule 01001111 01001011 * * * * * * * * * * * * * * * * */

Kai Buerhoop

unread,
Dec 14, 1990, 6:26:38 AM12/14/90
to
I got a problem with the 'del'-command.
I've got a certain file, which I can normally list with 'dir',
but which, if I want to rename it, copy it or delete it cannot be
modified.
DOS says: "Cannot find file"

Anyone an idea?

--
Kai Buerhoop
E-Mail: Kai.Bu...@arbi.informatik.uni-oldenburg.de
***no fuzz in here***

Ajay Shah

unread,
Dec 14, 1990, 7:33:16 PM12/14/90
to
In article <OTTO.90De...@tukki.jyu.fi> ot...@tukki.jyu.fi (Otto J. Makela) writes:
>In article <40...@uniol.UUCP> Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
> I got a problem with the 'del'-command.
> I've got a certain file, which I can normally list with 'dir',
> but which, if I want to rename it, copy it or delete it cannot be
> modified. DOS says: "Cannot find file"

How about a simple explanation. Consider a directory containing
two files

abc.pas
abc.txt


You say "dir abc*" and Microsoft's wonder correctly says

abc.pas
abc.txt

Now you say something like "copy abc* nul" or "del abc*" it won't
work because the morons implement wildcards differently for dir
as compared with everything else!!

Motto of the day: Microsoft sucks!

--
_______________________________________________________________________________
Ajay Shah, (213)734-3930, ajay...@usc.edu
The more things change, the more they stay insane.
_______________________________________________________________________________

Richard Maine

unread,
Dec 14, 1990, 9:50:02 PM12/14/90
to
On 15 Dec 90 00:33:16 GMT, ajay...@alhena.usc.edu (Ajay Shah) said:
Ajay> Nntp-Posting-Host: alhena.usc.edu

Ajay> In article <OTTO.90De...@tukki.jyu.fi> ot...@tukki.jyu.fi (Otto J. Makela) writes:
>In article <40...@uniol.UUCP> Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
> I got a problem with the 'del'-command.
> I've got a certain file, which I can normally list with 'dir',
> but which, if I want to rename it, copy it or delete it cannot be
> modified. DOS says: "Cannot find file"

Ajay> How about a simple explanation.

How about a simpler one. I bet you have a file that contains
non-printable characters (or perhaps blanks, I forget whether they
can mess up messy dos worse than it usually is) in the file name.
It may appear like dir is showing you the file name, but it doesn't
always tell the truth, the whole truth, and nothing but the truth.

Try Norton, PC Tools or any of the other tools that will let you
delete (or rename) the file by point-and-shoot instead of by typing
its name on the command line. They usually work fine on such names
and avoid the difficulty of getting weird characters past the
command line parsing.

Ajay> Motto of the day: Microsoft sucks!

You didn't see me say that. But you didn't hear me contradict
it either. :-)

--

Richard Maine
ma...@elxsi.dfrf.nasa.gov [130.134.64.6]

fis...@sc2a.unige.ch

unread,
Dec 15, 1990, 4:37:59 PM12/15/90
to
In article <40...@uniol.UUCP>, Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
> I got a problem with the 'del'-command.
> I've got a certain file, which I can normally list with 'dir',
> but which, if I want to rename it, copy it or delete it cannot be
> modified.
> DOS says: "Cannot find file"
>
> Anyone an idea?

Could be that what you see is not what you've got. I bet that dir finds the
file because of the implicit '*.*' pattern (have you tried 'dir strange.fil'?)
This means that you could delete it with 'del *.*', also...

Frankly, my only idea is that the filename (or the extention) contains blank
characters, i.e. char 255, or worse, a mixture of regular blanks (char 32)
and 255-blanks.

You could check it with something like 'dir>test' and 'debug test', wich shows
the real file names. It's probably easier make a copy first. Let's say your
file appears as 'HMM X ' in the directory listing, which you took as
meaning 'hmm.x', try 'copy hmm?????.x?? ok.now'. (BTW: the file must not be
empty for that!)

Hope this helps

Markus Fischer, Dpt of Anthropology, Geneva CH

60276000

unread,
Dec 15, 1990, 6:25:09 PM12/15/90
to

how about a non-printing char in the name? ex ^@abc would list as "abc";
unfortunatly i don't know of anyway to change this except:
1) create a temp dir
2) move all files to the temp dir one by one (not *.*)
3) do a del *.* & the offending program will go away
or --
execute a child command.com with a 32K environment
do:
for %i in ( *.* ) do set %i=%i
& the look at the env to see if a control char is there
or --
do a "dir > tmp" & look for control chars in tmp
--noesis

Roy M. Silvernail

unread,
Dec 16, 1990, 12:21:30 AM12/16/90
to
Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:

> I got a problem with the 'del'-command.
> I've got a certain file, which I can normally list with 'dir',
> but which, if I want to rename it, copy it or delete it cannot be
> modified.
> DOS says: "Cannot find file"
>
> Anyone an idea?

Yeah, a pretty good one. I'll bet you have a filename with a
non-printing character in it. Is the filename 7 characters or less? That
will be a clue.

The way to delete it is to use wildcards to match it. In fact (in an
extreme case), you might have to move all other files out of the
directory, and then 'del *.*' to rid yourself of it.

To rename it would be a bit trickier... perhaps a shell like PCTools, or
the filename completion of 4dos would be the ticket.

Hope this helps.
--
Roy M. Silvernail |+| roy%cyb...@cs.umn.edu |+| #define opinions ALL_MINE;
main(){float x=1;x=x/50;printf("It's only $%.2f, but it's my $%.2f!\n",x,x);}
"This is cyberspace." -- Peter da Silva :--: "...and I like it here!" -- me

Timo Salmi

unread,
Dec 16, 1990, 2:59:32 AM12/16/90
to
In article <28836@usc> ajay...@alhena.usc.edu (Ajay Shah) writes:
>In article <OTTO.90De...@tukki.jyu.fi> ot...@tukki.jyu.fi (Otto J. Makela) writes:
>>In article <40...@uniol.UUCP> Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
>> I got a problem with the 'del'-command.
>> I've got a certain file, which I can normally list with 'dir',
>> but which, if I want to rename it, copy it or delete it cannot be
>> modified. DOS says: "Cannot find file"
>
>How about a simple explanation. Consider a directory containing
>two files
... rest of the valid, possible cause deleted ...

A very simple question to the original poster of the problem. Have
you run chkdsk? Another potential cause besides Ajay's
blanks-in-the-name is that there is something wrong with the file or
the fat. Has been know to happen.

...................................................................
Prof. Timo Salmi (Moderating at anon. ftp site 128.214.12.3)
School of Business Studies, University of Vaasa, SF-65101, Finland
Internet: t...@chyde.uwasa.fi Funet: gado::salmi Bitnet: salmi@finfun

Keith Petersen

unread,
Dec 16, 1990, 5:34:49 AM12/16/90
to
Another thing that can cause a file to be undeletable is if it has the
same name as a loaded device driver.

Keith
--
Keith Petersen
Co-SysOp, Detroit Download Central 313-885-3956 (212/V22bis/HST/V32/V42bis)
Internet: w8...@vela.acs.oakland.edu, w8...@eddie.mit.edu, w8...@brl.mil
Uucp: uunet!umich!vela!w8sdz BITNET: w8sdz@OAKLAND

Carl Schelin

unread,
Dec 18, 1990, 9:11:32 AM12/18/90
to
In article <MAINE.90D...@altair.dfrf.nasa.gov>, ma...@elxsi.dfrf.nasa.gov (Richard Maine) says:
>On 15 Dec 90 00:33:16 GMT, ajay...@alhena.usc.edu (Ajay Shah) said:
>> In article <OTTO.90De...@tukki.jyu.fi> ot...@tukki.jyu.fi (Otto J. Makela) writes:
>>>In article <40...@uniol.UUCP> Kai.Bu...@arbi.informatik.uni-oldenburg.de (Kai Buerhoop) writes:
>>> I got a problem with the 'del'-command.
>>> I've got a certain file, which I can normally list with 'dir',
>>> but which, if I want to rename it, copy it or delete it cannot be
>>> modified. DOS says: "Cannot find file"
>>
>> [ removal of "simple" solution]
>
> [removal of "simpler" solution]

Jeeze, what a bunch of "simple" solutions! :)

Filename: File .nam

Dir works fine, but can't delete it.

Try: del file????.nam

bye-bye file....

assuming that you don't have any other files called File????.nam. (If so, rename them
first!)

Carl Schelin
t...@mailer.jhuapl.edu

0 new messages