admin管理员组

文章数量:1419168

I am adding a shortcut in desktop using WixV5 but icon is not coming. How can I add an ICo to shortcut.

The code I used is

   <Component>
    <File Source="../camviewer.exe" />
            <Shortcut Name="camviewer" Directory="DesktopFolder" Advertise="yes" />
            <Shortcut Name="camviewer" Directory="ProgramMenuFolder" Advertise="yes" />
  </Component>

ProgramMenuFolder also I am nto getting camviewer

I am not able to find reference part in visual studio.

I am adding a shortcut in desktop using WixV5 but icon is not coming. How can I add an ICo to shortcut.

The code I used is

   <Component>
    <File Source="../camviewer.exe" />
            <Shortcut Name="camviewer" Directory="DesktopFolder" Advertise="yes" />
            <Shortcut Name="camviewer" Directory="ProgramMenuFolder" Advertise="yes" />
  </Component>

ProgramMenuFolder also I am nto getting camviewer

I am not able to find reference part in visual studio.

Share Improve this question edited Jan 30 at 12:01 Sijith asked Jan 29 at 7:54 SijithSijith 3,96018 gold badges65 silver badges109 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

Use the Icon attribute to reference an Icon element with the icon you want to use for three advertised shortcut.

<File ...>
   <Shortcut ... Icon="MyIcon" />
</File>

<Icon SourceFile="path/to/my/shortcuts/foo.ico" />

本文标签: wix5How to add ico using wix installer v5Stack Overflow