• Please review our updated Terms and Rules here

Deleting Files on DOS3.3

Dwight Elvey

Veteran Member
Joined
Jun 21, 2003
Messages
4,991
Location
Santa Cruz
Hi
I've run into a problem. I have been running a program
that when you open a file that doesn't exist, it will create
a file of zero size, if that file name doesn't exist.
This is great for someone that never makes a mistake.
This person is not me.
I've been able to delete files using some utility DOS3.3
tools for most of my mistakes. I have one problem case
though and that is that I've managed to generate a file name
with garbled jibberage. It has a mixture of inverted and
blinking text.
Is there an easy way to delete such a file. It is really
annoying when doing a CATALOG.
Dwight
 
reminds me of olden days when we were embedding ^H in the file name to do nifty disk catalog or inserting ctrl characters in file name to make file deletion difficult :D
 
Hi
I'll play around and see if it works for me.
If worst comes to worst, I can always transfer the good
files to another disk and reformat the original.
Dwight
 
Oops!
I'd forgot that many, including myself, just look at New Posts and not always
pay attention to what forum it is posted in.
It is an Apple IIe.
Dwight

Oops here too for the same reason. I just assumed PC. (Oh well - I'm logged in now.) That means that my suggestion of just using DM (M. Mefford) won't work. Nevertheless any of those little programs which highlight and then do an action (like delete) are likely to work. There are probably hundreds of those. Also, in DOS 2.0 and above I always use file completion (using tab) so if you can type the first character, you are likely in business unless there is a space, in which case the file utility will still be needed.

I'm probably out to lunch here - sorry. I don't even know if you can type anything on an Apple or if they use utilities. But yes, I've scratched my head over the same problem. Getting a space in a file name while typing too quickly has caused much grief.
 
Could you possibly read the file name in via basic (maybe query you for each file found) and delete the string name when found? Not sure if http://www.calormen.com/applesoft/reference.htm has any new ideas for ya.
IIRC there is no "Apple sanctioned" way of retrieving the directory of the disk in DOS 3.3 programatically. Typical "loader" programs written in BASIC actually executes a <ctrl-D>CATALOG and then stitch together the complete file names by retrieving the corresponding text page memory locations where the file names are expected to be. That means hidden characters (ctrl characters) cannot be retrieve in this manner since the text page memory would only contain displayable characters; none of the ctrl characters could be retrieved. I think there are a few pokes floating around (probably in Beagle Bros Peek/Poke charts) that can "patch" DOS 3.3 image in memory to display ctrl characters in file names as inverse/flashing character in CATALOG output, but I don't know offhand where that can be found.

You can however retrieve the content of a directory as a text file under ProDOS just by opening it and then reading it.
 
Hi Dwight, the easiest way is oldschool, just copy the other files on the disk to another disk, then format your disk. The autocreate is a nice feature, ONERR command in applesoft might be generated if no file exists, but can't remember, it's been a while.

Vince
 
Hi
I've just been looking through a book called
'Inside Apple IIe'
It has enough info on RWTS that I believe I can
just read out the offending sector and modify it.
Then I just write it back.
Dwight
 
Hi
It worked. I found where to put the 0FF in the VTOC
and did it. Now a CATALOG is clean.
I feel so manly now.
Dwight
 
Back
Top