DataLab is a compact statistics package aiming at exploratory data analysis. Please visit the DataLab Web site for more information....


GetRegValueAsInt

Declaration: GetRegValueAsInt (RootKey: TRegRootKey; SubKey, ValueID: string): double;
The function GetRegValueAsInt reads a value of the Windows registry and interprets and returns it as an integer value. The parameter RootKey defines the root key and the parameter SubKey specifies the key (including its path) used within the branch of the root key. The parameter ValueID specifies the value to be retrieved.

The function returns the registry value always as an integer value, no matter whether the value is stored as an integer or as a string. If the type of the stored value is unknown, non-existant or not supported then the function returns a zero value. If the value is a string value of a combination of digits and characters then the leading digits are read as an integer and the rest of the string is ignored.