| Extracted from Pike v7.8 release 866 at 2018-07-18.

[Top]

# Method RegGetKeyNames()

Method RegGetKeyNames

  `array(string) RegGetKeyNames(int hkey, string key)`

Description

  Get a list of value key names from the register.

Parameter `hkey`

  One of the following:

  `HKEY_CLASSES_ROOT`
  `HKEY_LOCAL_MACHINE`
  `HKEY_CURRENT_USER`
  `HKEY_USERS`

Parameter `key`

  A registry key.

Returns

  Returns an array of value keys stored at the specified location if any. Returns `UNDEFINED` on missing key . Throws errors on other failures.

Example

      > RegGetKeyNames(HKEY_CURRENT_USER, "Keyboard Layout");
        (1) Result: ({
          "IMEtoggle",
          "Preload",
          "Substitutes",
          "Toggle"
         })

Note

  This function threw errors on missing key in Pike 7.6 and earlier (see System.RegGetKeyNames_76() ).

Note

  This function is only available on Win32 systems.

See also

  RegGetValue() , RegGetValues() , System.RegGetKeyNames_76()