Advertised Shortcuts point at the KeyPath of the Component they are contained in. You need to put the Advertised Shortcut in the same Component as the target File and the File must be the KeyPath. That's a Windows Installer restriction.
If you want to put your Shortcut in a different Component then you can't use Advertised. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of OneReallyCoolApplication Sent: Friday, September 14, 2007 15:57 To: wix-users@lists.sourceforge.net Subject: [WiX-users] Problems attempting to advertise a shortcut Hi, I am trying to create an advertised desktop shortcut. The problem is that in the component containing the shortcut, I cannot set KeyPath = "yes", or else I will get errors with the ORCA validation tool and the advertising doesn't work. If I set KeyPath = "no", then I must have a file under the component that has KeyPath = "yes", and a shortcut under that file. However this is extraneous since that file is also installed somewhere else in my code, and there are problems with opening that shortcut after it has been installed. Before I just had the shortcut directly under the shortcut's component (it was non-advertised), and it worked fine. My code looks like the following: <Directory Id="DesktopFolder" Name="Desktop"> </Directory> <Directory Id="PROGDIR" Name="PROG_.3" LongName="prog-1.3.3"> <Component Id="ProgShortcut" Guid="..." KeyPath="no"> <File Id="ProgShortcutFile" Name="Prog.exe" Source="..\Prog.exe" DiskId="8" Vital="no" KeyPath="yes"> <Shortcut Id="ProgShortcut" Directory="DesktopFolder" Name="Prog" WorkingDirectory="..." Icon="ProgIcon.exe" Advertise="yes"> <Icon Id="ProgIcon.exe" SourceFile="..\Prog.exe" /> </Shortcut> </File> </Component> </Directory> The program is "Prog" and "..." represents some GUID (for simplicity). Thanks for any help. -- View this message in context: http://www.nabble.com/Problems-attempting-to-advertise-a-shortcut-tf4445762.html#a12685182 Sent from the wix-users mailing list archive at Nabble.com. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users