0
  <Component Guid="{27E3322C-C85D-4451-A06D-21B524878CA0}">        
    <File Source="$(var.AutomatedIDSystem.TargetPath)" KeyPath="yes">

      <Shortcut Id="APSShortcut"
                Name="APS"
                Advertise="yes"
                Description="Something!"
                WorkingDirectory="INSTALLFOLDER"
                ShortName="APS"
                Directory="DesktopFolder" Icon="$(var.AutomatedIDSystem.TargetPath)" IconIndex="0" />                    
    </File>
  </Component>

This works fine if i remove the icon and iconindex

However I want an Icon to be there. I have an ico file or if you can tell me how to use the application icon, that would be preferred (incase we update our Icon, the Desktop Icon would update too)

software is fun
  • 7,286
  • 18
  • 71
  • 129

1 Answers1

0

try with Icon element. you need to provide icon id and icon path.Only supported is .exe and .ico.
Like this <Icon Id="Icon id" SourceFile="path to .exe or .ico"/>

And provide the same id to shortcut element Icon tag.

So you example will look like

<Component Guid="{27E3322C-C85D-4451-A06D-21B524878CA0}">        
    <File Source="$(var.AutomatedIDSystem.TargetPath)" KeyPath="yes">

      <Shortcut Id="APSShortcut"
                Name="APS"
                Advertise="yes"
                Description="Something!"
                WorkingDirectory="INSTALLFOLDER"
                ShortName="APS"
                Directory="DesktopFolder"   Icon="Icon id" />    

               <Icon Id="Icon id" SourceFile="path to .exe or .ico"/>

    </File>
  </Component>
Nimish
  • 709
  • 3
  • 16