The release options of clickonce do not have the options for creating shortcuts on the desktop, and many customers are used to using Desktop shortcuts.
Everyone knows that clickonce ProgramThe actual path is not fixed. Whenever the program is updated to the new version, the startup location will change, so that the traditional shortcut creation method is not easy to use.
By studying the shortcut in the Start menu, I found that it is actually a file with a suffix of. appref-ms and the content in it is in the text format, for example:
Http: // ZJJ/windowsapplication26/win26.application # win26.application, culture = neutral, publickeytoken = 6e8580a27fa3dbc7, processorarchitecture = msil
As you can see, there is no address for storing the actual executable files. It is a common address, and the new version is released immediately, which is also easy to use.
With this discovery, it is easy to create a desktop shortcut: Create a text file with the suffix. appref-MS on the desktop.
Text Content:
1. Release it on your own development machine.
2. Open the Start Menu, find the shortcut file, and open it in notepad.
Note that the text encoding format is Unicode.