excel vba read registry key value

The solution for “excel vba read registry key value” can be found here. The following code will assist you in solving the problem.

‘VBA function to READ from the Windows Registry:

Public Function RegRead(Key$) As String
On Error Resume Next
With CreateObject(“wscript.shell”)
RegRead = .RegRead(Key)
End With
If Err Then Err.Clear
On Error GoTo 0
End Function

‘NB: Always backup the Windows Registry before accessing it!

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

Similar Posts