Reads the name of a subkey according to its instance.
RegEnumKey ( "keyname", instance )
A registry key must start with "HKEY_LOCAL_MACHINE" ("HKLM") or "HKEY_USERS" ("HKU") or "HKEY_CURRENT_USER" ("HKCU") or "HKEY_CLASSES_ROOT" ("HKCR") or "HKEY_CURRENT_CONFIG" ("HKCC").
When running on 64-bit Windows if you want to enum a key specific to the 64-bit environment you have to suffix the HK... with 64 i.e. HKLM64.
RegDelete, RegEnumVal, RegWrite
#include <MsgBoxConstants.au3>
Example()
Func Example()
Local $sSubKey= "",$sEnumKey= "under HKLM\SOFTWARE:"&@CRLF &@CRLF
; Loop from 1 to 10 times, displaying registry keys at the particular instance value.
For $i= 1To 10
$sSubKey= RegEnumKey ("HKEY_LOCAL_MACHINE\SOFTWARE",$i)
If @error Then ExitLoop
$sEnumKey&="#"&$i&@TAB &$sSubKey&@CRLF
Next
MsgBox ($MB_SYSTEMMODAL,"RegEnumKey Example",$sEnumKey)
EndFunc ;==>Example