home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 3 Comm
/
03-Comm.zip
/
EASL2PRF.ZIP
/
GETDISK.INC
< prev
next >
Wrap
Text File
|
1990-03-20
|
1KB
|
35 lines
# Gets the list of available drives and puts them in an array
# We are going to assume that A: and B: are available, so we'll just
# test the hard drives.
application GETDRIVES
integer Cnt
string DriveLet
subroutine GetDrives (integer:NumDrives) is
set pointer to SPTR_WAIT
copy "Loading, please wait\n█" to InitMsg
change InitializeST text to InitMsg
start local GETDRIVES "MPGDISK.EXE"
begin guarded
response to line "ALL DONE" from GETDRIVES
stop GETDRIVES
leave block
response to line "Drives=" from GETDRIVES
extract from input # parse line into drives
skip "="
while (marker <= length of input) loop
extract from input
skip to marker
take 1 DriveLet
if (DriveLet = "@") then
leave loop
else
add to DiskDriveLB
insert DriveLet ":"
end if
end loop
end # guarded
set pointer to SPTR_ARROW