Jan Schreuder on .Net

.Net code samples, experiences, observations

View my professional profile on LinkedIn

Recent Posts

Tags

News

  • Inappropriate comments will be deleted at my discretion.

    The information and code samples in this weblog is provided "AS IS" without warranty of any kind, either expressed or implied, including but not limited to the merchantability and/or fitness for a particular purpose.

Community

Email Notifications

Tool suppliers

Tools

General

Microsoft

Favorite blogs

Archives

How to: Change options in a Windows Installer package using Orca

In the last couple of weeks I created a windows service for my current assignment. In order to deploy this service I created an installer package which works fine. But the administrators at this company asked if I could set the default value for the "Install app for yourself, or for anyone who uses this computer" radio button group to anyone.

Of course, I said, silently laughing for being asked to do such a simple task. But boy, was I wrong!smile_baringteeth

The installer, like the windows service, was created using VS 2003. I tried looking for a property with which I could change the default value for that radio button group. And I couldn't. I tried Google and all I could find was that, unless I used VS 2005, I had to use an application called Orca to do this manually.

Set Everyone as default in installer

Suppose you want to have the "Everyone" option in the folder form of your installer to be the default. Then you would have to take the following steps to change this, once the MSI file has been created:

  1. Start Orca and open the MSI file you want to change.
  2. You will see two grids. The one on the left contains the tables in the MSI file, the one on the right the properties and values stored in that table.
  3. In the grid "Tables" look for the table  Property and select that table.
  4. In the grid on the right, look for property FolderForm_AllUsers and select that property.
  5. Change the value to ALL.
  6. Save the installer and close Orca.

When you run the installer, you will see that the property is now set to "Everyone" instead of the "Just me" which is the regular default value.

Why is this not useful?

First of all, this works. And I could do this for my client. But why has Microsoft made this so difficult? I'm not the only one with this problem, and there are more options one might like to change. For example, you may wish to force a reboot after the installation has completed. Again something you need to do using Orca.

I'm forced to manually change this when I create a new installer. We're currently running tests on the application and for each fix we need to create a new installer. So you can image that I'm not too thrilled having to change this option by hand for each fix I need to deploy.

If there is anyone out there that has an better solution, please let me know. If it can be done by changing something in the VS 2003 installer project, that would be my first preference. If it can be done using a post-build action, again that would suit me just fine. I eagerly await any comments.

Leave a Comment

(required) 

(required) 

(optional)

(required) 


Please add 8 and 5 and type the answer here: