Pascal Scripting: InstallOnThisVersion

Prototype:

function InstallOnThisVersion(const MinVersion, OnlyBelowVersion: String): Boolean;

Description:

This function is deprecated. Returns True if an entry with the specified MinVersion and OnlyBelowVersion parameters should be installed. If an invalid version string is passed, an exception will be raised.

This function is provided for backward compatibility only, and may be removed in a future release. New scripts should use GetWindowsVersion or GetWindowsVersionEx instead.

Remarks:

Prior to Inno Setup 5.5.0, this function returned irInstall rather than a Boolean True value. irInstall is now defined as an alias for True.

Example:
// Old method, deprecated
function IsWindowsXPOrLater: Boolean;
begin
  Result := InstallOnThisVersion('0,5.1', '0,0');
end;

// New method
function IsWindowsXPOrLater: Boolean;
begin
  Result := (GetWindowsVersion >= $05010000);
end;
See also:

GetWindowsVersion
GetWindowsVersionEx