As the Desktop Icon is created by the MSI, it's somehow possible to include a condition into the creation (create a property, place a control on a UI and bind it to the property, create a component containing the shortcut and bind it to the property too, reference the component in the main feature).
For the first setup, this condition can be set through an installer-checkbox ("Create a Desktop Icon").
There is already a checkbox during the initial setup which allows the
user to choose whether the desktop shortcut is to be installed.
For further setups/updates the setup might remember this choice through an .ini file in the setup directory (or a registry key). If the shortcut belongs to a distinct feature that can be chosen on installation, maybe the MSI can handle it itself.
Since the WiX Shortcut cannot be a KeyPath, a RegistryValue is used as
the KeyPath and signals whether the Shortcut has been installed i.e.
whether the user has chosen to have a desktop shortcut installed
during the initial setup.
Upon update, the RegistryValue is read in order to determine whether
the Shortcut is installed i.e. whether the user has chosen to have the
desktop shortcut installed during the initial setup. If the user has
chosen to have the desktop shortcut installed during the initial
setup, the update reinstalls it i.e. if the user has manually deleted
it from the desktop in the time between the initial setup and the
update, the update does not know about it.
The question here is whether we want to find a way to determine
whether the user has manually deleted the shortcut? Can we be sure
that the deletion was on purpose or by accident i.e. does the lack of
the desktop shortcut signal to the update that the user has changed
their mind after the initial setup?
On Mon, Jul 4, 2011 at 5:34 PM, Bauersachs Ingo <firstname.lastname@example.org> wrote: