开发者

application shortcut trying to reinstall application

开发者 https://www.devze.com 2023-01-01 05:40 出处:网络
I have created a deployment file(msi) using VS Setup project. This msi file create a shortcut in desktop.During deployment I have added some predefined data files (.xml/text) into it.Application short

I have created a deployment file(msi) using VS Setup project. This msi file create a shortcut in desktop.During deployment I have added some predefined data files (.xml/text) into it.Application shortcut working fine i.e. it open the application and running fine.

But once I delete some data files from installation location, and then click application shortcut, it started installing the application and copied all those files into the original installation location again. My question i开发者_如何学Gos how to stop this re-installation after deletion of files.

Thanks, Pritam


You are experiencing the "Repair" feature of Windows Installer.

This is being triggered because you're installing an Advertised shortcut.

If you dislike this behavior, do not specify the shortcut as Advertised.

This MSDN article on the Shortcut Table gives you some info on specifying Advertised vs. non-Advertised.

Sadly, Visual Studio does not have the same kind of customization capability as a real installer development environment like InstallShield or WiX, so what you're trying to do is tricky. More information here.


From this post:

Another common misconception is when attempting to disable self healing within a component, as self healing is triggered when Keypath are missing assumptions are made to delete the keypath to stop self healing. In actual fact if you wish to stop self healing on a single component the correct method is to remove the components component GUID from the component table. (this will be explained in more detail in the section on packed GUID's)

You can do specified manipulation using Orca (manually). Or you can use WiRunSQL.vbs (Win 7 SDK) script to do this automatically as PostBuildEvent command.

0

精彩评论

暂无评论...
验证码 换一张
取 消