VS 2005 and Setup and Deployment Project Shortcuts
-
I have created a windows executable program via a C# VS 2005 project. This is not a published or 'Click Once' project. I also created a setup and deployment project for this application, and built the corresponding "setup.exe" and .msi files for the install. Within this setup and deployment project I created a shortcut to point at the windows executable, and have placed this shortcut in the 'User's Program Menu' special folder. When I install this application on a PC with XP or Vista operating systems everything appears to go fine, and the shortcut in the user's program menu is created. However, when I click the shortcut it always searches for the ".msi" file used in the installation, and if I have removed the flash drive I installed the application from, the shortcut will not work. I need to delete the shortcut included with the install, and create a new shortcut that points at the installed executable, to avoid this problem. Does anyone know, or have any thoughts, as to why the shortcut I am installing via the 'Setup and Deployment' project always needs access to the ".msi" file to work? Like I said, I have not published or, at least not intentionally, built this application as a 'Click Once' project. Thanks...
-
I have created a windows executable program via a C# VS 2005 project. This is not a published or 'Click Once' project. I also created a setup and deployment project for this application, and built the corresponding "setup.exe" and .msi files for the install. Within this setup and deployment project I created a shortcut to point at the windows executable, and have placed this shortcut in the 'User's Program Menu' special folder. When I install this application on a PC with XP or Vista operating systems everything appears to go fine, and the shortcut in the user's program menu is created. However, when I click the shortcut it always searches for the ".msi" file used in the installation, and if I have removed the flash drive I installed the application from, the shortcut will not work. I need to delete the shortcut included with the install, and create a new shortcut that points at the installed executable, to avoid this problem. Does anyone know, or have any thoughts, as to why the shortcut I am installing via the 'Setup and Deployment' project always needs access to the ".msi" file to work? Like I said, I have not published or, at least not intentionally, built this application as a 'Click Once' project. Thanks...
What is the target of the shortcut? Make sure its to the exe.
only two letters away from being an asset
-
What is the target of the shortcut? Make sure its to the exe.
only two letters away from being an asset
-
FWIW, the target is fine, it is the EXE. I must have some setting that is forcing the project to act like a click once, published project. But I'm obviously not seeing the forest for the trees.
You checked the properties to make sure ClickOnce wasn't checked I assume. I've seen this behavior with other apps, it may not have anything to do with yours, it could be a dependency that isn't present. Have you tried on other machines?
only two letters away from being an asset
-
You checked the properties to make sure ClickOnce wasn't checked I assume. I've seen this behavior with other apps, it may not have anything to do with yours, it could be a dependency that isn't present. Have you tried on other machines?
only two letters away from being an asset
Thanks for the responses, but ClickOnce is definitely not checked. I imagine if a dependency was not present then I still would be having problems after deleting and manually re-creating the shortcut in the Program's menu, but everything is fine when the shortcut is manually created. I've tried the install on multiple machines using XP or Vista operating systems with the same result. Fortunately the installation does not need to be done on very many machines, so I'm going to throw in the towel for the time being and just manually create the shortcut.
-
Thanks for the responses, but ClickOnce is definitely not checked. I imagine if a dependency was not present then I still would be having problems after deleting and manually re-creating the shortcut in the Program's menu, but everything is fine when the shortcut is manually created. I've tried the install on multiple machines using XP or Vista operating systems with the same result. Fortunately the installation does not need to be done on very many machines, so I'm going to throw in the towel for the time being and just manually create the shortcut.
Shame you never got an answer on this one. I have the same issue. I thought I must be doing something wrong, but can't work out what it is. Did you ever work it out? Thought it maybe because I made the shortcut to the Primary Output of xyz Project, but your post said you made it to the exe
-
Shame you never got an answer on this one. I have the same issue. I thought I must be doing something wrong, but can't work out what it is. Did you ever work it out? Thought it maybe because I made the shortcut to the Primary Output of xyz Project, but your post said you made it to the exe
Yeah, I did sort of work it out. Turns out that, by default, that is apparently automatically how VS 2005 does its setups; and I do not believe there is an override. So instead I used the 'Orca MSI Editor' tool to modify the installer created by VS 2005 to use the shortcut I wanted. If you are unfamiliar with the tool, google for Orca MSI Editor and you will find some downloads. I believe it does come with the Windows Installer SDK, but you can download just that tool if you do not want the entire SDK.
-
Yeah, I did sort of work it out. Turns out that, by default, that is apparently automatically how VS 2005 does its setups; and I do not believe there is an override. So instead I used the 'Orca MSI Editor' tool to modify the installer created by VS 2005 to use the shortcut I wanted. If you are unfamiliar with the tool, google for Orca MSI Editor and you will find some downloads. I believe it does come with the Windows Installer SDK, but you can download just that tool if you do not want the entire SDK.
Thanks very much for the help there. ORCA did work. I did find the whole thing pretty tricky though For the benefit of anyone else trying this in the future: this article kid of helped: http://support.microsoft.com/kb/830612[^] but it took this article to tell me that one needs to format the Target as [#] http://bytes.com/topic/net/answers/411545-clicking-created-shortcut-triggers-reinstallation[^] I would have hoped it was easier, but not surprised at the Microsoft Magic. Think I need to look for a better deployment tool