views:

1095

answers:

1

i've created a web setup project and i wanted it to create a desktop shortcut to the web application (ex: http://localhost/xx/yy.aspx). up to this point it was pretty easy: i created a shortcut (doesnt matter where), gave it the url i wanted, added this to the User's Desktop special folder of my web setup project, and it was placed on the desktop after the installation. but then i wanted to display my custom shortcut icon. i set the icon of the shortcut i've created on my file system. then i re-included this to the setup project. however after the installation the shortcut kept showing the default IE icon again. (i tried these on windows 2003 server, on win xp the shortcut showed up iconless)

after some trials i found another way: i recreated an iconless shortcut on my file system, opened my web setup project, included this shortcut and my icon to Web Application Folder under File System on Target Machine, then clicked on User's Desktop, right clicked on the right hand side blank area, selected Create New Shortcut and chose the shortcut i've just added. Then under User's Desktop i clicked on the newly created shortcut, opened the Properties window and set its Icon property to my included icon. These steps solved it all both on 2003 server and win xp.

Though this wasnt really a question i wanted to share it anyways because it was quite annoying.

A: 

So was the problem you were not including the actual ico, exe or dll file containing the icon in the installer? shortcut files (.lnk) do not actually contain a copy of the icon, just a link to them.

Justin Dearing
my shortcut file was not a .lnk shortcut but a url (pointing to the address of the web site) The problem was: creating the shortcut by specifying the target url and the shortcut icon, and then including this to the setup files didn't work. Creating a url shortcut inside the setup project in VS and specifying the icon from the Properties window there solved it.
davsan