xcall MIAMEX, MX_GETREG, key, subkey, name, value
(Windows only) This function allows you to retrieve values from the system Registry. Also see MIAMEX 138: Registry operations, which offers a more extensive set of registry access capabilities.
Parameters
key (Num or B,4)
must be one of the following specified values:
|
Symbol |
Value |
|
HKEY_CLASSES_ROOT |
&h80000000 |
|
HKEY_CURRENT_USER |
&h80000001 |
|
HKEY_LOCAL_MACHINE |
&h80000002 |
|
HKEY_USERS |
&h80000003 |
|
HKEY_PERFORMANCE_DATA |
&h80000004 |
|
HKEY_DYN_DATA |
&h80000005 |
subkey (String)
is the sub key within the specified key section of the Registry. This may have multiple parts, e.g. "Software\Microsoft\MediaPlayer\Player\RecentFileList".
name (String)
is the name of the particular value to look for within the specified subkey. You may specify a blank string to get the default value. (Many subkeys have only a default value.) For the subkey example given above, the likely names will be "File0", "File1", etc.
value (String)
will return the value of the specified item. It will be truncated if needed to fit in the variable provided.
Comments
This function is only useful for registry items of type string. Also, there is an internal limit of 256 bytes for the value. Even if you specify a larger variable for VALUE, if the actual data exceeds 256 bytes, the operation will fail and nothing will be returned. (This internal limit was 64 prior to the final 4.7 release.)
History
Build 963.3 of 10 Aug 2006: This function is now supported in ATE.