Description
Provides the ability to create, read, or write data to a RegistryKey from a given path.
NOTES
- Reference to AUExpress.Cells library.
- Grant modify permissions before attempting to change RegistryKey properties.
Syntax
Dim cls As New AURegistry
cls.RootType = RootType_HKEY_LOCAL_MACHINE
'do something
...
cls.Free
Set cls = Nothing
EXAMPLE 1
Get value data from a value name:
If cls.OpenKey("SOFTWARE\Autodesk\AutoCAD\R25.0\ACAD-8101", False) Then
Debug.Print cls.ReadValue("UPIRELEASE")
End If
EXAMPLE 2
Pulling a list of entries from Registry key:
If cls.OpenKey("SOFTWARE\Autodesk\AutoCAD\R25.0\ACAD-8101", False) Then
For Each vn In cls.ValueNames()
Debug.Print vn
Next
End If
EXAMPLE 3
Write values to a RegistryKey:
If cls.OpenKey("SOFTWARE\Autodesk\AutoCAD\R25.0\ACAD-8101", True) Then
cls.WriteValue "Version", 2024
cls.WriteValue "Production", "autechniques"
End If
See documentation for other examples.