Jump to content
Sign in to follow this  

Retrieve value from registry (advance)

Recommended Posts


$var = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version*\*may varied randomly*", "Loc")
MsgBox(4096, "Location name is:", $var)

because of it may varied randomly is there anyway to access that Loc "valuename" so that $var can be obtained

HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version*\ <--- these are fixed


another suggestion i could think of is anyway i can obtain the *may varied randomly* string so that i can merge them together. so my question would be anyway i can do the above, or anyway to obtain what 'folders' are in the "HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version*\"


thank you,


Edited by uppersoul

Share this post

Link to post
Share on other sites

problem solved just FYI

For $i= 1 to 10
    $var = RegEnumKey("HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version*\", $i)
    If @error <> 0 then ExitLoop
    MsgBox(4096, "SubKey #" & $i & " under HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version* ", $var)
    $var2 = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\*company*\*object*\*version*\"&$var, "Loc")
    MsgBox(4096, "Program files are in:", $var2)

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this