home *** CD-ROM | disk | FTP | other *** search
- ;+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- ;
- ; Name : GetDrv.ASM - A QB4+ FUNCTION which returns the ASC value of the
- ; current default drive.
- ;
- ; Revised : 4/20/90
- ;
- ; Notes : - Under DOS, this interrupt returns the following values -
- ;
- ; Drive A: = 0
- ; Drive B: = 1
- ; Drive C: = 2
- ;
- ; - This is a QB4+ FUNCTION which returns the ASCII value of
- ; the current default drive, for example -
- ;
- ; Drive A: = 65
- ; Drive B: = 66
- ; Drive C: = 67
- ;
- ;+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-
- .MODEL MEDIUM,BASIC
- .CODE
-
- GetCurrDrv proc
-
- mov AH,19h
- int 21h
-
- add AL,65 ; Convert drive spec to ASCII value
- xor AH,AH ; Zero out the hi byte
-
- ret
-
- GetCurrDrv ENDP
- END
-
- ;+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-