Profile photo of Steve White

About Steve White

Software Engineer

Steve WhiteDisabling Windows Installer Advertised Shortcuts in VS2010

About Windows Installer Advertised Shortcuts Problem

We recently migrated a product to Visual Studio 2010 and came across a problem whereby the programs shortcuts kept triggering re-installation of the application, even though the product had just been installed. Windows Installer Advertised shortcuts ensure that the shortcuts always have an icon, even if users move from machine to machine. No matter what, we could not find the root cause of this issue, so we looked at disabling this mechanism in the MSI.

Editing Generated MSI’s Using Orca

We used Microsofts ‘Orca’ tool to edit the MSI and scripted this as a post build event in VS2010. To do this we performed the following steps:

  1. Install Windows 7 SDK
  2. Install Orca.msi contained within the SDK: C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\Orca.Msi
  3. Set the following Visual Studio post build event for the installer project:

cscript “C:\Program Files\Microsoft SDKs\Windows\v7.0\Samples\sysmgmt\msi\scripts\WiRunSQL.vbs” “$(BuiltOuputPath)” “INSERT INTO Property(Property, Value) VALUES (‘DISABLEADVTSHORTCUTS’, ‘1’)”

This ensured every installer thereafter was generated with advertised shortcuts disabled. There are a plethora of options which can be set by the Orca tool, just look at the ‘scripts’ folder in the above post build event for examples of what you can do.



2 thoughts on “Disabling Windows Installer Advertised Shortcuts in VS2010

  1. This solution worked for the case of the ‘shortcut’ but not for ‘file-type’. If I open a file of the type associated with my exe it reverts back to the unwanted behavior. Have you also experienced this?

    • Hi Bill. In our case fortunately we did not have any file type associations with the application so it wasn’t an issue. It’s been some time since I was involved in this project but I remember there were quite a few options made available in the orca tool which may help you.

Leave a Reply