GetOperatingSystemInfo Function

Action

Returns the major and minor version and the build number of the operating system.

Include File

Kernel.bdh

Syntax

GetOperatingSystemInfo(
  majorVersion : out long, 
  minorVersion : out long, 
  buildNumber : out long optional) : boolean;

Return value

  • true if successful

  • false otherwise

Parameter Description
majorVersion The major version of the operating system
minorVersion The minor version of the operating system
buildNumber The build number of the operating system

Example

dcltrans
  transaction TMain
  var
    majorVersion, minorVersion, buildNumber : number;
  begin
   if GetOperatingSystemInfo(majorVersion, minorVersion,  buildNumber) then
      Print(string(majorVersion)+" "+string(minorVersion)+" "+string(buildNumber));
    end;
end TMain;

Output

6 1 7600