Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/wix/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.net InstallExecuteSequence表包含一个操作';移除现有产品';在两个不同的位置声明_.net_Wix_Upgrade - Fatal编程技术网

.net InstallExecuteSequence表包含一个操作';移除现有产品';在两个不同的位置声明

.net InstallExecuteSequence表包含一个操作';移除现有产品';在两个不同的位置声明,.net,wix,upgrade,.net,Wix,Upgrade,为了在WiX升级期间保留配置文件,我在InstallExecuteSequence中添加了以下行: <RemoveExistingProducts After="InstallFiles"></RemoveExistingProducts> 为什么会发生这种情况?以及如何修复它?您应该尝试删除此行: <RemoveExistingProducts After="InstallFiles"></RemoveExistingProducts>

为了在WiX升级期间保留配置文件,我在InstallExecuteSequence中添加了以下行:

<RemoveExistingProducts After="InstallFiles"></RemoveExistingProducts>

为什么会发生这种情况?以及如何修复它?

您应该尝试删除此行:

<RemoveExistingProducts After="InstallFiles"></RemoveExistingProducts> 

并添加Schedule=“afterInstallExecute”,如下所示:

<MajorUpgrade Schedule="afterInstallExecute" 
              DowngradeErrorMessage="Newer version installed. Exiting." />


您必须在源文件中声明RemoveExistingProducts两次。搜索并删除它。@Glytzhkof Search返回RemoveExistingProducts的一个匹配项,这是我添加的行。MajorUpgrade也会安排RemoveExistingProducts可能这就是冲突的原因。谢谢,@Glytzhkof!这有助于消除错误。
<MajorUpgrade Schedule="afterInstallExecute" 
              DowngradeErrorMessage="Newer version installed. Exiting." />