The shortcuts work fine in my system, but do not work or do not display an image when installed in a different system.

asked 06 Sep '11, 06:55

Jake's gravatar image

Jake ♦♦
796222226235
accept rate: 98%


This is likely to be happening because you hardcode the path to the image or executable to the location of the files in your system, and do not include those files as part of your installation. Make sure you include the file the shortcut points to and the image or icon the shortcut is using as part of your installation. Make sure they are referenced as ${installdir}/path/to/image.png so the right path is specified once installed. On Unix, make sure also that if the target is an executable, it has the right permissions ( chmod +x filename ).

link

answered 06 Sep '11, 06:55

Jake's gravatar image

Jake ♦♦
796222226235
accept rate: 98%

I'm confused about this. I'm having the same problem where my desktop shortcut and start menu shortcut icons are not showing up on windows. They show up on mac though. I am hardcoding the path to the icon files on my drive, but the mac one seems to have been built into the installer correctly. Thank You!

(02 Sep '12, 21:45) ddouglas_KMI

I have found a way around this for windows icons.

If you include the icon files as part of your installation and then reference them as described above for your shortcuts you can then delete them as a post-installation action and have the shortcuts still display the icons correctly on windows (this doesn't seem to be necessary for mac). For example, I created a folder called Temp in my default component which contains my icon file. This is unpacked only on windows, and my shortcuts reference the icon here.

  <windowsIcon>${installdir}/Temp/myicon.ico</windowsIcon>

Then, after installation is successful, I can delete the Temp folder and my shortcut still retains the icon image.

<deleteFile>
<path>${installdir}/Temp</path>
<ruleList>
    <platformTest>
        <type>windows</type>
    </platformTest>
</ruleList>
</deleteFile>

I find this helps keep clutter out of my installation directory.

link

answered 03 Sep '12, 17:03

ddouglas_KMI's gravatar image

ddouglas_KMI
21446
accept rate: 50%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×41
×29

Asked: 06 Sep '11, 06:55

Seen: 2,274 times

Last updated: 03 Sep '12, 17:03