Click or drag to resize

UtilIsMinimumRequiredVersion Method

Tests whether the current platform version is at least equal to the supplied major and minor version numbers, returns false if this is not the case

Namespace:  ASCOM.Utilities
Assembly:  ASCOM.Utilities (in ASCOM.Utilities.dll) Version: 3c9121baba46811fe6e53a58a05935662261416d
public bool IsMinimumRequiredVersion(
	int RequiredMajorVersion,
	int RequiredMinorVersion


Type: SystemInt32
The required major version number
Type: SystemInt32
The required minor version number

Return Value

Type: Boolean
True if the current platform version equals or exceeds the major and minor values provided
This function provides a simple way to test for a minimum platform level. If for example, your application requires at least platform version 5.5 then you can use code such as this to make a test and display information as appropriate.
Const requiredMajorVersion as Integer = 5
Const requiredMinorVersion as Integer = 5 ' Requires Platform version 5.5
Dim Utils as New ASCOM.Utilities.Util
isOK = Utils.IsMinimumRequiredVersion(requiredMajorVersion, requiredMinorVersion)
If Not isOK Then 
   ' Abort, throw exception, print an error or whatever.
See Also