You should be able to supply your own icon using the @Icon attribute. The Shortcut element causes entries into the Shortcut table, which Windows Installer uses in the CreateShortcuts and RemoveShortcuts actions. In CreateShortcuts, Windows Installer uses the shell interfaces for shortcut generation (I believe it is IShellLink to assemble the shortcut data, and possibly IPersistFile to write it out).
It is possible that the PDF icon is not set per-machine, in which case there would be ambiguity when identifying it. I don't really know much about the implementation details of shortcuts, so I'm not the expert (yet <smile/>) to ask. -----Original Message----- From: Nick Ball [mailto:nick.b...@grantadesign.com] Sent: Thursday, October 08, 2009 3:47 AM To: General discussion for Windows Installer XML toolset. Subject: Re: [WiX-users] Shortcuts for peruser/permachine Hmmmm... I've rejigged the installation and since it is perMachine I'm now doing the shortcut something like this: <Directory Id="ProgramFilesFolder"> <Directory Id="INSTALLLOCATION" Name="PerMachine"> <Component Id="Test" Guid="*"> <File Id="product.txt" KeyPath="yes" Name="product.txt" Source="Product.txt" > <Shortcut Advertise="yes" Id="product.Shortcut" Directory="PerMachineFolder" Name="PerMachine"/> </File> <RemoveFolder Directory="PerMachineFolder" Id="RemovePerMachineFolder" On="uninstall"/> </Component> </Directory> This works, but I do not get an icon. For my application, I could add my own, but I also install a PDF to the start menu, and I'd like that to pick up whatever the PDF icon is on the system (which happens if the install is perUser, but not perMachine). Of course, this makes some kind of sense, because user A might have a different application for a file type than user B, but is there any way of forcing this? Cheers Nick -----Original Message----- From: Blair [mailto:os...@live.com] Sent: Wednesday, October 07, 2009 6:59 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] Shortcuts for peruser/permachine The ICE wants shortcuts in components with HKCU registry keypaths because it is possible to remove the ALLUSERS value from your installation from the commandline even if it is present in the Property table (making your installation per-user instead of per-machine, even if that breaks other things in your installation and even if you have guarded against that). My personal belief is that if you have guarded against per-user installs and only support per-machine installs AND if your shortcuts (and the components that install them) are otherwise completely in per-machine space (not in any user's profile) you can ignore/suppress that particular ICE report. Be sure to run smoke regularly on your MSIs to evaluate all reports to ensure that you don't have any surprises that ICE tests for if you can't suppress just one report at a time. -----Original Message----- From: Nick Ball [mailto:nick.b...@grantadesign.com] Sent: Wednesday, October 07, 2009 8:25 AM To: wix-users@lists.sourceforge.net Subject: [WiX-users] Shortcuts for peruser/permachine Hi All, I've read the How To in the WiX documentation on this, but I am confused. My application is typically installed by administrator, yet students need to be able to log on and use it, so it makes sense to make the installer perMachine. The example of how to create a shortcut, however, seems to be per user. I have been using this and occasionally received the install error 'Could not open key HKEY_CURRENT_USER\Software\my company etc etc' If I'm doing a perMachine install, why do I need to create a registry key under HKEY_CURRENT_USER? What is the best practice for doing this? Regards Nick ------------------------------------------------------------------------ ---- -- Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users