Book Image

WiX Cookbook

By : Nicholas Matthew Ramirez
1 (1)
Book Image

WiX Cookbook

1 (1)
By: Nicholas Matthew Ramirez

Overview of this book

Table of Contents (20 chapters)
WiX Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Adding an icon to a shortcut


Adding your own branded icons to your shortcuts will make them stand out. We can even have different icons for different purposes, such as one to denote the help documentation and another for a shortcut to the application itself. In this recipe, we'll see how to include an icon in our installer and have it displayed on a shortcut.

Getting ready

To prepare for this recipe, perform the following steps:

  1. Create a new setup project and call it IconShortcutInstaller.

  2. Set up your directory structure to include a folder in the Start menu:

    <Directory Id="TARGETDIR" Name="SourceDir">
      <Directory Id="ProgramFilesFolder">
        <Directory Id="INSTALLFOLDER" Name="My Company" />
      </Directory>
      <Directory Id="ProgramMenuFolder">
        <Directory Id="MyCompanyStartMenuFolder" 
          Name="My Company" />
      </Directory>
    </Directory>
  3. Include a text file named Sample.txt in the project and add a Component element to the Product.wxs file...