Set the Install Type to PerMachine, and take a look at:

http://wixtoolset.org/documentation/manual/v3/howtos/files_and_registry/create_start_menu_shortcut.html

Carter

Quoting faujong <fiefie.ni...@gmail.com>:

> I am new to WiX.
> I am able to create a Desktop shortcut.
> I tried to create a menu shortcut that will show up under the "All
> Programs", but when I compile the program, I get errors "The directory WIX
> is in the user profile but is not listed in the RemoveFile table." and "An
> error occurred while validating.  HRESULT = '8000000A'".
>
> I also get warnings "Component 'WIXVBShortcut' has both per-user and
> per-machine data with an HKCU Registry KeyPath." and "Mismatched component
> reference. Entry 'ApplicationStartMenuShortcut' of the Shortcut table
> belongs to component 'WIXVBShortcut'. However, the formatted string in
> column 'Target' references file 'WIXVB.exe' which belongs to component
> 'ProductComponent'. Components are in the same feature.".
>
> How can I create both Menu shortcut and Desktop shortcut ?
> Thank you.
>
> This is my Product.wxs:
> <Product Id="*" Name="WIXVBSetupProject" Language="1033" Version="1.0.1.0"
> Manufacturer="aaa" UpgradeCode="blabla">
>       <Package InstallerVersion="200" Compressed="yes" 
> InstallScope="perMachine"
> Platforms="x64"/>
>       <MajorUpgrade Schedule="afterInstallExecute" DowngradeErrorMessage="A 
> newer
> version of [ProductName] is already installed." />
>       <MediaTemplate />
>
>       <Feature Id="ProductFeature" Title="WIXVBSetupProject" Level="1">
>               <ComponentGroupRef Id="ProductComponents" />
>       </Feature>
> </Product>
>
> <Fragment>
>       <Directory Id="TARGETDIR" Name="SourceDir">
>               <Directory Id="ProgramFiles64Folder">
>                       <Directory Id="IGINDEX" Name="IG Index">
>                               <Directory Id="INSTALLFOLDER" 
> Name="WIXVBSetupProject" />
>                       </Directory>
>               </Directory>
>
>
>               <Directory Id="DesktopFolder" Name="Desktop"/>
>
>
>               <Directory Id="ProgramMenuFolder">
>                               <Directory Id="WIX" Name="WIX VB " />
>               </Directory>
>       </Directory>
> </Fragment>
>
> <Fragment>
>       <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
>               <Component Id="ProductComponent" Win64="yes">
>                       <File Source="$(var.WIXVB.TargetPath)" KeyPath="yes">
>                               <Shortcut Advertise="yes"
>                                       Id="MyProductDesktopShortcut"
>                                        Directory="DesktopFolder"
>                                        Name="WIXVB"
>                                        WorkingDirectory="INSTALLLOCATION"
>                                        Description="WIX VB "
>                                        Icon="Chart.ico">
>                                       <Icon Id="Chart.ico" 
> SourceFile="$(var.WIXVB.TargetPath)" />
>                               </Shortcut>
>                       </File>
>               </Component>
>
>               <Component Id="WIXVBShortcut" Win64="yes">
>                       <Shortcut Id="ApplicationStartMenuShortcut"
>                                 Name="WIX VB "
>                                 Description="WIX VB "
>                                 Target="[#WIXVB.exe]"
>                                 WorkingDirectory="INSTALLFOLDER"/>
>                       <RemoveFolder Id="WIX" On="uninstall" />
>                       <RegistryValue Root="HKCU"
>                                  Key="Software\Microsoft\WIXVB"
>                                  Name="installed"
>                                  Type="integer"
>                                  Value="1"
>                                  KeyPath="yes" />
>               </Component>
>       </ComponentGroup>
> </Fragment>
>
>
>
>
> --
> View this message in context:  
> http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/How-to-create-Menu-Shortcut-tp7593054.html
> Sent from the wix-users mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> Subversion Kills Productivity. Get off Subversion & Make the Move to  
> Perforce.
> With Perforce, you get hassle-free workflows. Merge that actually works.
> Faster operations. Version large binaries.  Built-in WAN optimization and the
> freedom to use Git, Perforce or both. Make the move to Perforce.
> http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>




------------------------------------------------------------------------------
Subversion Kills Productivity. Get off Subversion & Make the Move to Perforce.
With Perforce, you get hassle-free workflows. Merge that actually works. 
Faster operations. Version large binaries.  Built-in WAN optimization and the
freedom to use Git, Perforce or both. Make the move to Perforce.
http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to