DOSVersion

Returns the version numbers of the current version of DOS.

Syntax:

DOSVersion (level)

Parameters:

(i) level @MAJOR or @MINOR.

Returns:

(i) integer or decimal part of DOS version number.

 

@MAJOR returns the integer part (to the left of the decimal).
@MINOR returns the decimal part (to the right of the decimal).

If the version of DOS in use is 5.0, then:

DOSVersion(@MAJOR) == 5
DOSVersion(@MINOR) == 0

 

Example:


i = DosVersion(@MAJOR)
d = DosVersion(@MINOR)
If StrLen(d) == 1 Then d = StrCat("0", d)
Message("DOS Version", "%i%.%d%")
See Also:

Environment, FileVerInfo, Version, VersionDLL, WinVersion