home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Microsoft Programmer's Library 1.3
/
Microsoft-Programers-Library-v1.3.iso
/
sampcode
/
msj
/
msjv4_4
/
basic
/
getdrive.bas
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
BASIC Source File
|
1989-03-23
|
344 b
|
15 lines
'***** GetDrive.Bas - BASIC function that returns the current drive
'syntax: Drive$ = CHR$(GetDrive%)
' where: Drive$ is returned as "A", "B", and so forth
DEFINT A-Z
DECLARE SUB DosQCurDisk(SEG Drive, SEG DriveMap&)
FUNCTION GetDrive%
CALL DosQCurDisk(Drive, DriveMap&)
GetDrive% = (Drive - 1) + ASC("A")
END FUNCTION