GetRegValueType

Gets the data type of the value of a variable in the Windows registry.

Function Group Execution Windows Embedded Thin Client
GetRegValueType System Info Synchronous Supported Supported Not supported

Syntax

GetRegValueType( numMainKey, strKey, strValueName )
numMainKey
Numeric tag with the following possible values:
0 HKEY_LOCAL_MACHINE
1 HKEY_CLASSES_ROOT
2 HKEY_CURRENT_USER
3 HKEY_USERS
4 HKEY_CURRENT_CONFIG
5 HKEY_PERFORMANCE_DATA
strKey
Path where the value is located in the Main Key.
strVariableName
Name of the variable to get. The maximum length is 255 characters.

Returned value

1 Variable type is String.
0 Variable type is DWord.
−1 Invalid number of parameters or invalid Main Key.
−2 Variable type is not supported. You can only read DWord or String values from the registry.
−3 Failed to read the variable value; verify that you have the proper security rights.

Examples

Tag Name Expression
Tag GetRegValueType( 0, "HARDWARE\DESCRIPTION\System", "SystemBiosDate" ) // Returned value = 1
Tag GetRegValueType( 2, "Control Panel\Desktop", "Smooth Scroll" ) // Returned value = 0