Reading version info from registry

J

JB

Hi Folks,
I'm trying to write a macro which is independant of version and location
of office install but I'm having trouble reading the registry with the
code I have. I've used this code many times before in the
HKEY_CURRENT_USER key but never in the HKEY_LOCAL_MACHINE key.

Here's what I have : -

Dim AppVer As String
Dim x as Integer
Dim Tester as string

AppVer = Application.Version
x = InStr(AppVer, ".")
VerNum = Left(AppVer, x - 1)
Tetser = GetSetting("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\" _
& VerNum & ".0" & "\Word\", "InstallRoot", "Path")

Confused

J
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top