Sign in to follow this  
Followers 0
lonewolf217

unable to read regkey for Exchange 2007 install location

3 posts in this topic

I am having a really strange problem that I cannot figure out the simple solution

$exDir = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Exchange\v8.0\Setup","MsiInstallPath")

MsgBox(0,"test",$exDir)

I thought these two lines would read the registry key value for the install location and then display it in a message box, but the message box is always empty. I have checked and doublechecked the registry key location and value, copy/pasting them multiple times so I dont see where I might be going wrong.

Anyone have an idea where I screwed it up ?

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

I am having a really strange problem that I cannot figure out the simple solution

$exDir = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Exchange\v8.0\Setup","MsiInstallPath")

MsgBox(0,"test",$exDir)

I thought these two lines would read the registry key value for the install location and then display it in a message box, but the message box is always empty. I have checked and doublechecked the registry key location and value, copy/pasting them multiple times so I dont see where I might be going wrong.

Anyone have an idea where I screwed it up ?

I searched the entire registry on a Windows 2003 Standard AD Domain Controller, and couldn't find a single instance of "MsiInstallPath" under anything. There are lots of keys for Exchange, but keys like WorkingDir are spread out across the various component's registry entries, not grouped under "Setup".

:D

P.S. v8 is Exchange 2007 (64bit only), which I don't have. Your path might be 64bit-specific:

$exDir = RegRead("HKLM64\SOFTWARE\Microsoft\Exchange\v8.0\Setup","MsiInstallPath")

I can't test that.

:D

Edited by PsaltyDS

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

yes, Exchange 2007 is 64bit, I right clicked the key name and said Copy Key Name, then pasted into Auto-It. I assumed it would copy all the required text.

I will try the HKLM64 idea though

and yes, this key structure only shows up if you have Exchange 2007 installed

Edit: yes, this did work. Thanks!

Edited by lonewolf217

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  
Followers 0