home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
World of Shareware - Software Farm 2
/
wosw_2.zip
/
wosw_2
/
QBAS
/
PBC22B.ZIP
/
PBC$BAS.ZIP
/
GETSER.BAS
< prev
next >
Wrap
BASIC Source File
|
1993-01-01
|
879b
|
26 lines
' +----------------------------------------------------------------------+
' | |
' | PBClone Copyright (c) 1990-1993 Thomas G. Hanlin III |
' | |
' +----------------------------------------------------------------------+
DECLARE SUB GetDOSv (MajorVersion%, MinorVersion%)
DECLARE FUNCTION GetSerial00& (BYVAL DriveNr%)
FUNCTION GetSerial$(Drive$)
GetDOSv MajV%, MinV%
IF MajV% < 4 THEN
St$ = ""
ELSE
IF LEN(Drive$) THEN
D% = ASC(UCASE$(LEFT$(Drive$, 1))) - 64
ELSE
D% = 0
END IF
St$ = RIGHT$("00000000" + HEX$(GetSerial00&(D%)), 8)
St$ = LEFT$(St$, 4) + "-" + RIGHT$(St$, 4)
END IF
GetSerial$ = St$
END FUNCTION