4

I added a new shortcut.url file with the following:

[InternetShortcut]
URL=http://test.com/
IDList=
HotKey=0
IconFile=C:\Program Files\Test\logo.ico
IconIndex=0

This works on XP - the shortcut displays the logo.ico. But on Windows 7, the shortcut is white, without the icon.

The icon exists in the location on Windows 7. I also noticed that if I use the Windows GUI to set the icon it works. Even though I am setting it to the same icon.

Is there a setting (maybe) where you have to include a path for the icon to work?

How can I get it to work on Windows 7?

1
  • Just tried the exact same text above with a random ICO (on Win7 x64), and it worked perfectly. If the icon wasn't present the internet shortcut had a blank/white icon of course, but adding the icon to the specified location and pressing F5 made it show up as expected for the .URL file. Have you tried rebuilding the icon cache?
    – Karan
    Dec 4, 2012 at 23:26

1 Answer 1

0

It's fairly stupid that I cannot post comments to the original post, since creating an answer to ask for extra information isn't the right way to do it.

I have never modified shortcuts using a text-editor, rather just right-clicked them and chosen properties. Try opening the shortcut properties and click "Change icon".

I suppose you could be having this problem because there is multiple icons in your ICO file so you have to specify which of them to use by adding ",1" after it. I'm not completely certain about how that works though.

1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .