/build/static/layout/Breadcrumb_cap_w.png

InstallLocation

In the registry, how do I find out the install location of an installed product.
After installing a msi package, I can find the package code, product code and upgrade codes of the package and other information in the registry.
Under

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-21-1482476501-1220945662-725345543-1000\Products\525580035BBEF1E4F8E7485822C7FF05\InstallProperties

for the installed product code, I can get properties such as InstallSource, Version, DisplayName, Publisher, etc.
But the Property "InstallLocation" is always empty.

How do I find the installation folder that was selected by the user during installation?

Thank you!

0 Comments   [ + ] Show comments

Answers (3)

Posted by: MSIPackager 18 years ago
3rd Degree Black Belt
0
Try looking here HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{product-code-guid} for an InstallLocation value.

Cheers,
Rob.
Posted by: CCRMZ 18 years ago
Yellow Belt
0
Thank you Rob for responding!

Yes, I had already checked that also, (should have mentioned it before), but the same thing: just an empty value.


I see some other products with an install location, but most with-out one.

Any other ideas?

Thank you for your help!
Posted by: CCRMZ 18 years ago
Yellow Belt
0
Ok.

A Custom Action needs to be created in order for the InstallLocation to get set (using the ARPINSTALLLOCATION property).

I'm using the VB Studio .NET Installer to create the package and it doesn't create a custom action to do this.
All of the other registry values get set by MsiExec, except this one. I wonder why not? In the SDK Help it states that this generally gets set using a custom action. There must be a reason for doing this.

So, I will post what I did for anyone else that may have this problem:

I edited the MSI product using ORCA.

1. To the CustomAction table add a new custom action:

Action Column: SetInstallLocation
Type column: 51
Source column: ARPINSTALLLOCATION
Target column: [TARGETDIR]
(Using InstallShield the Target may be [INSTALLDIR]

2. To the InstallExecuteSequence table add the action:

Action Column: SetInstallLocation
Nothing needed in the Condition column
Gave it a sequence number under the Sequence column.

This sequence number will be a number which is just before the CostsFinalize record's sequence number (Sort on this column-head click-to make sure the sequence number is correct)

In my package the CostsFinalize has a sequence number of 1000.
The record prior to this one is IsolatedComponents and has a sequence number of 950. So I gave the new SetInstallLocation record a sequence number of 975.

After installing the package, the registry shows the InstallLocation where it was installed, under the registry keys Installed Products and Uninstall Product Code for my package's Product Code .
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ