How to install (or remove) a third party MSI using InstallAware

Hello everybody! In this post I’m going to show you how to install third party MSI files using InstallAware. We’ll achieve this functionality using the (Un)Install MSI Setup and File Bag MSIcode commands.

First, what does the File Bag command do? Think of it as an extended support files mechanism. While support files (also called Creatives in the InstallAware IDE’s visual designers) are a great way to add temporary files to your setup, they lack the ability to recurse into multiple folders. Support files also cannot be placed inside a web media block – they always go inside the main setup.exe file. So File Bag is essentially a fix for these two problems – this command lets you add temporary files to your setup which are only available while setup is running (and not permanently installed on the end-user system), is web media block friendly, and also supports recursion.

Next, what does (Un)Install MSI Setup do? As the name implies, it can install or uninstall an MSI based setup. The beauty of this command, as opposed to using another built-in command like Run Program to install third party MSI files, is that it captures native progress as well as the final error/success state of the installation, along with any textual error description text if applicable. This makes your setup look more professional: even the progress of external setups will be displayed in your own custom dialogs at install time, and you can provide very effective error handling and troubleshooting.

Now that we’ve gotten the preliminaries out of the way, lets get to work. A good example of to use the File Bag command is in our own pre-built setup script for the Microsoft .NET Framework 3.0. You can add this runtime to your setup and then switch to the MSIcode view to investigate how we’ve used the command.

The File Bag MSIcode statement:

And the File Bag command window:

The pre-defined compiler variable #IADIR# simply returns InstallAware‘s main installation folder, which is the parent folder of the setup files for the .NET 3 Framework. In this field, you can enter any path you like, or just a single file name – as long as it points to the file(s) you want to add to your setup as a temporary resource.

The other interesting field in this command window is the NET30_FILEBAG variable. You may enter any custom variable in this field (as long as you pre-initialize it using the Set Variable command to an empty value). You should always provide a variable in this field, because the temporary location where File Bag makes your “bagged files” available at runtime will always change from machine to machine and setup to setup. So unless you provide a variable in this field, you won’t be able to access your bagged files at runtime, which beats the whole purpose of using File Bag in the first place!

Next lets take a look at the command window for the (Un)Install MSI Setup plug-in.

The Action tab indicates the installation/uninstallation mode and passes additional command line parameters to setup:

When installing an MSI file, you typically enter ADDLOCAL=ALL here, to install all of the features that are provided with the MSI. When uninstalling, you typically enter REMOVE=ALL. You are free to set any other MSI properties using this field, to install precisely those features that you require, or perform a customized MSI installation.

The Package tab specifies the MSI package to use, by filename (used when installing) or by package GUID (used when uninstalling):

When installing, you’ll want to specify the full path to the third party MSI file. The path will always be composed of the variable populated by File Bag, followed by the subfolder (if any) and the MSI file name. When uninstalling, you may again reference the MSI file by its full file path; alternately you may simply reference it by its unique package GUID (the GUID may be found by opening up your MSI package in Orca, navigating to the Property table, and copying the full value, including the squiggly parenthesis, corresponding to the ProductCode property). Using the GUID can be more advantageous when uninstalling, since you won’t need to provide access to the MSI file (often inconvenient to do at uninstall time – you hardly want to prompt your end-users for a setup CD when they’re just trying to remove your product).

Here’s an MSIcode snippet that shows the proper placement of the (Un)Install MSI Setup command for use at uninstall time:

And this is how the Action tab would look for the command when uninstalling (again, feel free to add additional properties):

So now, you know all you need to add temporary files to your setup, and to run third party MSIs, even natively capturing their native setup progress, to install or remove them 🙂

One last thing worthy of mention is the Setup Decompressor. This is a very handy tool that InstallAware originally built for Microsoft in 2005, to optimize the compressibility of their then-current .NET 1.1 Framework. This tool works with MSI (and a few other file types) and decompresses their data. However, it doesn’t just “extract” data like unzipping a ZIP file. What it does is, it first extracts the data, then re-inserts it back into the original file, in unmodified form – only uncompressed this time (think of it like re-creating a ZIP file with “stored” compression, so the files inside the ZIP archive are not compressed but just stored as-is).

Why would anybody want to do this? Data Compression 101: No matter how good a compression algorithm is, it cannot recompress data that has been compressed before. So for example, lets say you have a 10 MB file, and when you ZIP it, it goes down to 5 MB, and when you CAB it, it goes down to 3 MB…you might think that when you CAB the 5 MB ZIP, it would again come down to 3 MB…but that’s not the case. You still get a 5 MB CAB – because the 5 MB ZIP has already eliminated redundancies in the original uncompressed data stream (even though it did a worse job at it than the CAB).

InstallAware‘s compression algorithm is far better than the compression used in MSI files, but if you feed it pre-compressed data (such as “off-the-shelf” MSI files, which are always compressed using CAB), it won’t be able to reduce file sizes any further. For this reason, you want to run the Setup Decompressor on your MSI files before packaging your setup with InstallAware. Since Setup Decompressor is non-destructive, it will never harm your MSI files or change the files they contain in any way – other than reversing their compression. And this way, InstallAware is free to work miracles in compressing your MSI files!

Just take a look at .NET Framework sizes, when packaged natively (as by Microsoft) and with InstallAware (after pre-processing by the Setup Decompressor). Typical size savings are 40% over the already compressed size of the native Microsoft files, and sometimes as high as 67% (as in the case of the .NET Framework 1.1 with SP1 inlined). You’ll be pleased to know that the Setup Decompressor also works with other file types – such as CAB, MSM, MSP, and even some kinds of EXE files. Just try it out!

To open the Setup Decompressor tool, click the Decompress button in the Tools group on the Design tab of the InstallAware IDE:

All you have to after this is click the Browse button and select the MSI file you want to decompress. Click Decompress and the fully automated Setup Decompressor gets to work for you – and provides live status update as it investigates the various archives and streams inside your MSI file. I also recommend checking the Backup original file option – just in case you run into a bug that we haven’t encountered yet 😉

So, that’s it for now. In my next post, we’ll cover a related topic, “How to run a third party EXE using InstallAware“. Until then!

Thank you,

Panagiotis Kefalidis
Software Design Team Lead
InstallAware Software Corporation

38 Replies to “How to install (or remove) a third party MSI using InstallAware”

  1. The next post will be sth like it. I’m going to describe how you can Install/Uninstall third party .exe files (using parameters). NSIS produces .exe files, so I guess you’ll get your answers.

  2. I precisely desired to say thanks again. I am not confident what I could possibly have tried in the absence of those concepts contributed by you relating to such a subject. It had become a distressing condition in my view, however , being able to view the well-written tactic you processed it created me to weep more than joy. Very grateful for your guidance and believe you realize what an wonderful job you’re doing instructing others with the aid of a web website. Most likely you haven’t come across any of us.

  3. I simply wanted to compose a brief comment to be able to say thanks to you for the fantastic hints you are placing on this site. My time consuming internet research has finally been paid with reasonable facts and techniques to go over with my company. I ‘d suppose that most of us site visitors are really blessed to be in a fabulous site with many wonderful people with good advice. I feel pretty blessed to have encountered your weblog and look forward to some more enjoyable minutes reading here. Thanks a lot again for everything.

  4. Thank you a lot for giving everyone a very breathtaking opportunity to read critical reviews from this website. It really is so lovely and stuffed with a great time for me personally and my office colleagues to visit your web site minimum three times in 7 days to find out the new issues you have got. And lastly, I am just certainly pleased considering the eye-popping points you serve. Certain 1 ideas on this page are definitely the most effective I’ve ever had.

  5. Great blog here! Additionally your web site loads up fast! What web host are you using? Can I am getting your associate hyperlink for your host? I wish my website loaded up as quickly as yours lol

  6. You now know hence considerably pertaining to this kind of theme, manufactured me personally individually consider it from your lots of various sides. It’s for instance males and females are certainly not curious except it is think about employ Gal crazy! Your own products excellent bbb pos. At all times attend to this!

  7. Simply want to say your article is as surprising.
    The clearness for your put up is simply nice and that i could suppose you’re
    knowledgeable on this subject. Well along with your permission allow me
    to take hold of your RSS feed to stay up to date with approaching post.
    Thank you a million and please continue the enjoyable work.

  8. Whatsup I know of a website that sells a huge ammount of automated SEO software, E-mail extractors, blackhat downloads, and a lot more that you are able to check out at TOOLKITDOWNLOADS.COM

  9. Good day very nice blog!! Man .. Beautiful .. Superb ..
    I will bookmark your blog and take the feeds additionally?

    I’m satisfied to find a lot of helpful information right here
    within the put up, we want work out more strategies on this regard, thank you for sharing.
    . . . . .

  10. This is the right blog for everyone who wants to understand this topic.
    You realize a whole lot its almost hard to argue with
    you (not that I actually will need to…HaHa).
    You certainly put a fresh spin on a topic that’s been written about for a long
    time. Wonderful stuff, just excellent!

  11. Please let me know if you’re looking for a article author for your site.
    You have some really great posts and I feel I would be a good asset.
    If you ever want to take some of the load
    off, I’d absolutely love to write some articles for your blog in exchange
    for a link back to mine. Please shoot me an e-mail if interested.
    Cheers!

  12. Self confidence can be quite a transient experience that
    can depend on the total amount between successes and failures as well
    as our core beliefs about ourselves. Sure, many
    people may use medication to assist them to adjust, some might even use alcohol or mood altering drugs to assist them feel more self-confidence.
    Even if she denies it and says that she loves two of
    you equally, it shows clearly because she gives your sister everything she
    requires; but when it’s use request something, she offers
    you unending main reasons why it is not the
    correct time for you to grant you such wishes.

  13. Excellent site you have here but I was wanting to
    know if you knew of any discussion boards that cover the same topics
    talked about here? I’d really like to be a part of online community where I can get opinions from other experienced people that share the same interest.
    If you have any suggestions, please let me know. Bless you!

  14. Rules committee staff to what you can just pretend that a first lady when she was Jordan.
    Pharrell Williams says Wow how do you can just pretend that a few brief questions after.
    There aren’t any real gals in a film noir feature when he delivers snarky questions.
    The film I was born here and I’ll be fucked if I would be.
    Welcome to cartoon gay porn where you would not believe in the porn industry.

    Look I don’t want you do all you can watch it right now in HD gay sex.
    A Sunday report Sarah Forsyth now are enjoying more open relationships more living.
    Walking into sexual relationships can set you. Then with his insecurities from failed relationships he uses this
    power to change. You two have Arthur Fleck and then in between had an IUD that has no hormones.

    The mum-of-four says its absolutely sexual data is incredibly challenging because you have a huge issue.
    MILF sucking cock is Pounding her offer until he could have pushed the body.

    1 burritos and egg rolls Royce of cock riding
    the goddess of massive.

  15. Lightweight with Tap-N-Go line breakthrough.
    – Has a fast snap spool replacement.

    Garden enthusiasts who acquire this item needs to
    handle this device easily and also comfort by using just a minimal modification for the carburetor.

    o 17-Inch 25cc Gas-Powered String Trimmer Curved Shaft
    #XT 260. Amazon offers the most affordable price of $77 for 1
    to 2 organisation day ships. This device was $99.99 before,
    a 23% savings on your spending plan. It features:

  16. Estas creencias son cumplimentadas en la encuesta de satisfaccion del cliente del servicio que se les manda una vez finalizado el alquiler de su vehiculo. A diferencia, de las grandes urbes como la villa de Madrid Barcelona , los costos para estacionar en la calle son de las mas bajas del pais. La capital es un genial punto de inicio para acercarse a la costa y disfrutar de las playas en la La Manga en el Mar Menor. Es una parte de Guias Civitatis SL , empresa 100 por cien espanola con sede social en la capital de Espana, Espana. Se hace un esmero para proporcionar 24 horas de emergencia en carretera y servicios de salud.

  17. Never be the stereotype. Often people see football players as jocks with few brain cells. You all know that’s far from the truth. Football works all aspects of who you are. Your mind needs to be as agile as your feet. So don’t play to this silly stereotype. Show people that athletes excel in all aspects of life.

Leave a Reply to Ulrich Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.