home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 6 File
/
06-File.zip
/
filtyp.zip
/
readme.1st
< prev
Wrap
Text File
|
1994-11-03
|
2KB
|
48 lines
This little external REXX Function (written in REXX) came about during
my search for an easy way for a REXX program to determine if a specified
drive was FAT, HPFS or a CD-ROM. The overall consensus seemed to be
that the only way to do this would be with a "C" program. There were a
few problems with this, not the least of which was:
1) I do not know how to code in "C"
2) I do not have a "C" compiler for OS/2 available to me.
I was also looking for a mechanism that I could distribute freely, which
meant I couldn't use any of the external functions provided by Quercus,
Watcom or GammaTech.
I had just about given up when I noticed that the "Performance 2.1"
product from "Clear and Simple" was identifying my partitions correctly,
and the programs are all written in pure OS/2 REXX. I looked into the
"SEESYS.CMD" program and found out how the author (Tony Pereira) did it.
It was fiendishly simple and clever. I used his technique (though not
his code) to write this little program. It should be invoked from
within a REXX program like this:
type = FileType(drivespec)
"type" will return FAT, HPFS or CD-ROM. There is no error checking in
this program (as you can tell if you look at the source). If you code
'drivespec' incorrectly, the program will cheerfully tell you that it is
a CD-ROM! 'drivespec' should contain the letter *AND* the colon (i.e.
'C:'). If you want to add some form of error checking, be my guest. I
am releasing this program into the public domain. I only ask that if
you make any modifications that you feel will be generally useful to
please send me a copy of your changes.
I recommend that anyone interested in REXX programming to get a copy of
"Performance 2.1" or "Performance 2.1 Plus" from "Clear and Simple,
Inc." It provides useful tuning information and OS/2 tools, as well as
some wonderfully clever REXX coding techniques. "Clear and Simple" can
be contacted at:
Clear and Simple, Inc.
P.O. Box 130
W. Simsbury, CT 06092
(203)658-1204
"Performance 2.1" should be available wherever you buy your OS/2
software.
Jaime A. Cruz, Jr.
72267.1372@compuserve.com