home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Zodiac Super OZ
/
MEDIADEPOT.ISO
/
FILES
/
03
/
ZSV_101.ZIP
/
ZSVIEW.DOC
< prev
next >
Wrap
Text File
|
1996-05-14
|
22KB
|
721 lines
ZSView - A viewer for ALLFILE.DIR
(C) 1996 End Users, Inc.
Table of Contents
Overview.................................................... 2
Before you begin............................................ 3
ZSView...................................................... 4
Usage....................................................... 4
Options..................................................... 4
Main Index.................................................. 5
File Viewing................................................ 6
Sort Menu................................................... 6
Save........................................................ 7
Files Needed / Files Deleted................................ 8
Error Messages.............................................. 9
Additional Notes............................................10
Speed.......................................................10
Disclaimer..................................................10
Revision History............................................11
- 1 - ZSView.DOC
Overview:
ZSView is a dedicated viewer for the file listings contained in
ALLFILE.DIR. ZSView will also handle the individual directories in
ALLFILES.ZIP as a whole, as if they were all contained in ALLFILE.DIR,
creating an index for all 97 directories. ZSView will handle any
individual directory up to about 2 Meg.
ZSView can also sort the file listings in a directory by Name,
Date or Size. And ZSView can handle the multiline file descriptions
up to 50 lines per listing.
ZSView is written in QB 4.0, so it will run on an XT (although
the sorting routines may be quite slooow on large directories).
Also included in the package is PRETREAT. This program is
run once before using either ZSView or ZS. PRETREAT corrects
problems in ALLFILE.DIR or the file directories which would cause
trouble for the search and sort routines in ZSView or ZS.
- 2 - ZSView.DOC
Before you begin:
If this is the first time you are running ZSView (or ZS)
then you must run PRETREAT.EXE before you run ZSView (or ZS).
PRETREAT corrects four problems in ALLFILE.DIR or the file
directories by use of these three options:
PRETREAT T X F
Options: T - Tabs are converted to 7 spaces. (Although in
the latest ALLFILE.DIR {4-2-96} there were
no tabs used.)
X - Useless lines with "@X80" contaminating the
filename area are removed.
Simultaneously, any lines longer than 80
characters are shortened to contain only
the first 80.
F - That portion of the DIR98 listing in
ALLFILE.DIR (between the two
=================== lines) which doesn't obey
the rule whereby multiline descriptions are
marked off with a vertical bar, "|", is
changed to comply. (This is not necessary
for the files in ALLFILES.ZIP -- no DIR98!.)
The few blank lines left and the two
=================== lines cause an
inconsequential problem when the file is
sorted: they all appear at the top or bottom
depending upon the type of sort done.
The options for PRETREAT may be run together or individually
as circumstances dictate.
- 3 - ZSView.DOC
ZSView:
ZSView is written in QB 4.0 and runs in glorious 16 color 80 x 25
text mode. ZS can be either in the directory with the files being
searched or on the path.
Usage:
ZSView
That's it! No options are needed. ZSView will scan the current
directory to determine which set of directories is being viewed.
ZSView first looks for a file called ALLFILE.DIR. When that's found,
ZSView then looks for the associated index file, ALLFILE.IDX. If
this is the first time you're running ZSView (or if you've had to
delete the index previously) then an index file will be created.
Once that's done without error, you'll be placed into the Main Index,
the table of contents for ALLFILE.DIR.
If the hard drive directory you're in doesn't contain ALLFILE.DIR,
then ZSView will look for a file called DIR01. If found, ZSView
assumes you are viewing the individual directories and then looks for
the associated index file ALLFILES.IDX. If the index file isn't
found, ZSView will create it and then launch you into the Main Index.
If neither ALLFILE.DIR or DIR01 is found, you will be dumped back
to the DOS prompt with an error message about not being able to find
any files to view. If you were trying to view the individual
directories contained in ALLFILES.ZIP and were simply missing DIR01,
then after you restore DIR01 you should delete ALLFILES.IDX and rerun
ZSView to recreate a new index.
Options:
Actually, there is an option you can use. If you wish ZSView to
start up in a specific directory, then include that number on the
command line:
ZSView ##
and ZSView will launch you into that directory for immediate viewing.
- 4 - ZSView.DOC
Main Index:
When ZSView begins (assuming the IDX file exists) it will place
you into the Main Index. This is a table of contents for the
directories contained in ALLFILE.DIR or the individual directories
originally packed in ALLFILES.ZIP.
A reverse video highlight bar will tell you which directory is
currently under consideration. Hitting "Enter" will allow you to
view the contents of that directory.
For other directories use the cursor keys to move about the Index.
You may call up a help menu for that by hitting "F1."
If you find a blank line nestled between two directory names,
this indicates a faulty ALLFILE.DIR or a missing directory, DIR##,
in the hard drive directory where you unzipped ALLFILES.ZIP. Should
you retrieve the missing directory or find an unblemished copy of
ALLFILE.DIR, delete the IDX file and let ZSView create a new one.
There is a Find function for the Index which is activated by
hitting the "F" key ("F" for "FIND"). You may look for a single-
line word or phrase up to 40 characters long. If found, it will be
highlighted in yellow on red as well as having the directory
highlight bar move to that line.
You may repeat the Find forwards or backwards by hitting "F3" or
"F4", respectively.
Just entering "F" and then exiting without entering a word to
find will clear the Find buffer and inactivate the "F3" and "F4" keys
until the next time a Find word is chosen.
You exit ZSView by hitting the "Esc" key from the Main Index.
- 5 - ZSView.DOC
File Viewing:
Hitting "Enter" from the Main Index will call up the directory
being highlighted at the cursor bar. Movement about this file is
similar to the Index with the exception that the "Home" and "End"
keys actually move you to the top and last full line of the file,
respectively.
To help remind you, a help menu can be summoned by hitting the
"F1" key, as in the Main Index.
Keys:
Up - Move one line up
Down - Move one line down
Pg Up - Move one page up
Pg Dn - Move one page down
Home - Move to first line
End - Move to last full page
F1 - Call this help message
F3 - Repeat last Find in forward direction
F4 - Repeat last Find in backward direction
F - Enter a phrase to Find (Limit 40 characters)
ESC - Quit File Viewing / Return to Main Index
Enter - Quit File Viewing / Return to Main Index
The "FIND" function in File Viewing works the same way as it does
in the Main Index.
To return to the Main Index hit either "Enter" again or "Esc."
The Line number in the lower right corner refers to the top line.
Sort Menu:
While in File Viewing, hitting "S" will call up the Sort menu bar
along the bottom row of the screen. Your choices are to sort by
(N)ame, (D)ate or (S)ize by hitting the indicated letter:
N - Sort the file by Filename in alphabetical order (A-Z)
D - Sort the file by Date in reverse order (Newest on top).
Within the same date, Sort is by Filename in A-Z order.
S - Sort the file by file Size in reverse order (Largest file
on top). For files of the same size, Sort is by Filename
in A-Z order.
- 6 - ZSView.DOC
Save:
You may save the file you are currently viewing by hitting "V" as
indicated on the bottom bar of the File Viewing screen. You may do
this before or after a sort has been performed.
Based upon the sort action taken prior to hitting Save, ZSView
will choose an extension for the filename of the file to be saved.
As an example, if you were viewing DIR23 (in either ALLFILE.DIR or
the directory itself unzipped from ALLFILES.ZIP) and had performed a
Name sort on the file, then, when you chose to save the results of
that sort, ZSView would automatically use the name DIR23.NAM for it.
(Similarly, a Date sort would use ".DAT" and a Size sort would use
".SIZ" for the filename extension.)
If the filename already existed, then an error message would
appear on screen and ask for a decision:
O - Overwrite the file
U - Use a different name of the type "SAVED.#" where # is a
number from 1 to 999
C - Cancel the Save and return to File Viewing
Of course, if the file had not been sorted yet, then saving it
would mean trying to save it with no extension. If the directory was
from ALLFILES.ZIP then the error message would appear, otherwise it
will be saved as is. Files are saved with the original 9-line header.
If a name can't be found for the file (generally only if Saved.1
thru Saved.999 already exist in the working directory), an error
message will appear advising you of that fact, the name currently
being used, and then you will be returned to the DOS prompt as the
program ends right there. However, the file will have been saved with
a name of the type "Temp_#" or "Temp_#.#", where # is a number from
1 to 999.
- 7 - ZSView.DOC
Files Needed / Files Deleted:
During its normal operation, ZSView needs to create several
temporary files. They have the general filename "Temp_#", where
# is a number from 1 to 999. Also files called "Temp_#.#" may be
created. ZSView checks to see if such files exist and will not
overwrite them unless they are zero byte files. When ZSView exits
smoothly, those files should be deleted. None of those files need
be present when ZSView starts up. You may delete them if they appear
after a normal exit from ZSView. (An abnormal exit, such as a reboot
might well leave behind those temporary files. You may delete them.)
NOTE: The temporary files created in the use of PRETREAT may be
as large as (or slightly more than) ALLFILE.DIR. Do not attempt
to run PRETREAT on a RAM disk unless you have a RAM disk which is
AT LEAST TWICE the size of ALLFILE.DIR (currently over 8 Meg).
ZSView will save the results of a sort if you wish it to do so.
If ZSView can't use the directory name plus an extension which
corresponds to the type of sort (i.e., "NAM" , "DAT", or "SIZ"), then
it will offer to save the file as "SAVED.#", where # is a number
from 1 to 999.
A third class of file ZSView generates is a temporary file of the
type "Temp_#.BAS." Normally those files are deleted before ZSView
finishes. If you see any files of that type and you have not
created them, they may be deleted without worry.
As noted in the beginning, the most important file ZSView needs
is the file to be viewed! ZSView's priority for determining that
has already been explained. Just remember that if any missing files
are restored, the IDX file should be deleted so a new one can be made.
Also note that any zero-byte files with the filenames of
ALLFILE.DIR or DIR01 would be deleted.
- 8 - ZSView.DOC
Error Messages:
ZSView will generate a few error messages if it finds certain
problems. The following ones will end the program immediately:
"E1: Problem Creating Index. Delete current Index and try again."
Do as it says! If the problem reoccurs, there is probably some
irregularity in ALLFILE.DIR or one of the DIR##. Try unzipping
a new one.
"E3: Unable to create a temporary file name. See manual for help."
As explained in the previous section, ZSView needs to make files
of the type "Temp_#", etc. If there are 999 of these files (from
1 to 999) then this error message appears. Rename or destroy all
those which serve no purpose. Under normal circumstances, ZSView
should not leave any files of that type around after a normal exit.
However, see message "E11."
"E9: Missing ALLFILES.DIR or DIR01"
ZSView was unable to determine which set to view. Check to see if
you are in the proper directory. If DIR01 was actually missing,
when it is replaced, delete ALLFILES.IDX and rerun ZSView to create
a new index.
"E11: Cannot find a suitable way to rename " file name ". Do it
manually."
As explained above, if there are too many files of the type
"Saved.#", where # is a number from 1 to 999, then ZSView will
be unable to save the given file. Look for a name of the type
"Temp_#.#" as the saved file so that it can be renamed as you see
fit.
The following errors will not end the program:
"E4: " File name "is missing. If found, delete current Index and
rerun."
In this condition, a directory which had been previously registered
in the IDX file has now disappeared. You may continue to view the
other directories, but when that one is found, delete the IDX file
and rerun ZSView to create a new Index.
"E14: File too big to work with. Returning to Index."
ZSView can deal with files up to 32,767 lines. It is possible that
eventually directory listings will surpass this figure. In that
case, ZSView will return you to the Index to view the other listings
which are still of a reasonable size for it to handle.
It is possible that on some systems QB will generate an "OUT OF
STRING SPACE" error message. If that happens, please inform us and
we will release a slightly slower version of ZSView which uses a
smaller buffer and should fix that problem.
- 9 - ZSView.DOC
Additional Notes:
You might find gaps in the %Done green bar as it goes across the
screen. This is most likely due to missing directory files, DIR##,
unzipped from ALLFILES.ZIP, or a corruption in ALLFILE.DIR. Either
replace the missing directories or unzip a new copy of ALLFILE.DIR.
(Either way, don't forget to run PRETREAT and recreate the IDX file.)
As mentioned, ZSView runs in 16-color, text mode. It makes a few
Basic DEF SEG calls to the B800 area where it expects to find normal
color video memory. If you are using a non-standard video card or
have an extremely unusual upper memory arrangement, then ZSView will
not work properly and you should not use it.
For the disk space deprived, ZSView may be compressed to around
52K by using PKLITE v1.5 with the -p option.
If you find any bugs in using ZSView, we'd like to hear about
them. Please leave a message here on the IF to Paul Zuber in Main
Board or e-mail to: paul.zuber@factory.com
Speed:
There are two times when speed might be an issue. First, when
you have to run PRETREAT. See the discussion in ZS.DOC on the
reasons for and against turning to a RAM disk.
The other issue of speed concerns the sorting routines. These
employ the well-known Quick-sort routine and are probably as fast
as they can be made for the moment without resorting to the use of
assembly language. The real bottleneck in the sort routine is not
the sorting itself but rather rewriting the file to disk after the
sort has been done. Due to the limitations of QB, there is no way
around that at the moment.
Disclaimer:
Simply, this software is provided "as is" without any warranties
or guaranties about its performance or suitability. You, the user,
assume all risk for its use.
This software is free for users of the INVENTION FACTORY BBS.
No fee may be charged for its distribution.
All copyright software and trademarks mentioned herein are the
property of their owners.
All rights reserved.
- 10 - ZSView.DOC
Revision History:
Version 1.00 - Inaugural release.
Version 1.01 - Added line length check to PRETREAT.EXE to shorten
lines over 80 characters long to just the first 80.
Added command line option to jump to a specific directory upon
startup.
- 11 - ZSView.DOC