home *** CD-ROM | disk | FTP | other *** search
- {DOS.INC :
- This returns a real number representing the DOS version of the
- system executing the program. It requires no types, variables or
- identifiers outside the body of the function.}
-
- FUNCTION DOS : Real; {returns DOS version number}
- VAR
- registers : RECORD
- al, ah : Byte;
- bx, cx, dx, bp, si, di, ds, es, flags : Integer;
- END;
- BEGIN
- registers.ah := $30; {Call MS-DOS function $30.}
- MsDos(registers);
-
- {The major version returns in al, the minor in ah.}
-
- DOS := registers.al+(1.0*registers.ah)/100;
- END; {DOS}
-
- { All of this horribly over-commented code, which should ARC admirably,
- is the product of
- Karl Brendel, CIS 73307,3101
- 718 East B Avenue
- Hutchinson, Kansas 67501 }
-