I would like to create a desktop shortcut for my clickonce deployed application. The IDE is VS2005 and there is no need for upgrading to 2008 yet.
Any help would be greatfully appreciated.
I would like to create a desktop shortcut for my clickonce deployed application. The IDE is VS2005 and there is no need for upgrading to 2008 yet.
Any help would be greatfully appreciated.
You cannot do this in ClickOnce, and that is by design:
One of the goals of ClickOnce was to make the user experience of installing and running rich client code as "web-like" as possible
[...]
In keeping with the web-like model we wanted to be as minimally invasive as possible in terms of shell footprint and opted to not "spam" the desktop with shortcuts (note that on the XP startmenu will light up with a notification that an app has been installed for ClickOnce apps).
as explained in this thread on social.msdn.microsoft.com.
The only workaround is to create the desktop icon yourself on first startup. But doing so is not recommended.
You might want to reevaluate whether your really need a desktop icon. I personally hate installers which do that.
If you have to stay with Visual Studio 2005, your only option is to write code to create the icon. Here's how to do it. However, be aware of the fact that if a user uninstalls your application, the desktop icon won't get removed.
If you ever upgrade to Visual Studio 2008 SP1, you'll get this feature out of the box.
Here you go. This explains exactly how to create a desktop shortcut programmatically for a ClckOnce deployment. Creating a Desktop Shortcut for a ClickOnce Application
This works just fine, and there is no risk involved.