/build/static/layout/Breadcrumb_cap_w.png

keep INSTALLDIR

Hello, I know that it can be set from the msi file or mst a property for INSTALLDIR that does not permit at install to change the installdir from command line. Does anyone know about it?

0 Comments   [ + ] Show comments

Answers (3)

Answer Summary:
Posted by: ekgcorp 10 years ago
10th Degree Black Belt
0
Are you asking if there is a way to KEEP"INSTALLDIR=c:\whatever" from being set and applying from a Command Line, and overwriting anything that you put in your MST?

If so, I have seen some vendors that set a property with a custom action that happens toward the end of the InstallExecuteSequence and replacing / over writing any properties added via MST. I got around this by putting a condition on the Custom Action that was looking for a Higher than set INSTALLLEVEL (a good amount of vendors set INSTALLLEVEL to 100, then I would put a condition of INSTALLLEVEL = 200 on that Custom Action so that it would never run.

Comments:
  • I heard about a property that when it is set in the msi the user/admin could not change the installdir from command line. Are you saying that "property" is a custom action? I don't know for sure what is it but I know that you can set an installdir for the msi and when someone try to install the msi msiexec /i x.msi INSTALLDIR="C:\blabla" the installation could not be made - EmanuelPopescu 10 years ago
Posted by: Badger 10 years ago
Red Belt
0

You can only change it if it exists. If you want to install your app somewhere else, and the INSTALLDIR property 'is not working' then the MSI might not be using INSTALLDIR. (check the Directory table for INSTALLLOCATION, APPDIR, also, others are available)

I have also seen with a few vendor MSI's that a CustomAction sets the install location (INSTALLDIR or other) , so you set it to what you want, and then the CA overwrites your change. grrrr

OR, the CA only runs during InstallUI sequence, so you install it silently and the app installs to the root of the C:\. double grrrr.


Comments:
  • I will try to make a CA for this. Thank you all for answering - EmanuelPopescu 10 years ago
    • hold the phone.... really a CA??? - Badger 10 years ago
      • I will try that but.......but my question was how to prevent at a installation of an msi to change the INSTALLDIR from command line :) - EmanuelPopescu 10 years ago
    • I think what Badger and I are trying to say is, be aware of what the vendor might be trying to do via CA. Creating one is more of a last resort. I would be more inclined to keep vendors CA from running that was changing the INSTALLDIR, then to create yet another CA to compensate what they are trying to do. - ekgcorp 10 years ago
      • yep.... you might need to re read your question.... If setting INSTALLDIR is not working, find out WHY, don't just write a CA. - Badger 10 years ago
      • so, the question is, how can you prevent the INSTALLDIR from being changed via the command line, you cant. since its in CAPITALS that means it is a public property, the significance of these is, they CAN be changed from the command line. you could change the MSI so that the INSTALLDIR was private not public. so maybe MyInstalldir. Then that would not be changeable from the command line, but it would still be able to be changed using the GUI (if the dialogue boxes have been created) or via an MST. - Badger 10 years ago
Posted by: EmanuelPopescu 10 years ago
Yellow Belt
0
"Answered"!

Comments:
  • Thank you Badger, I understand better how INSTALLDIR prop works. Thank you for your answer:) - EmanuelPopescu 10 years ago
 
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