Installer返回不正确的错误代码

Installer返回不正确的错误代码

本文介绍了Windows Installer返回不正确的错误代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在使用windowds安装程序(* .MSI)设置项目来为我的Windows桌面模块创建MSI文件。

使用

Hi All,
I am using windowds installer (*.MSI) set-up project to create MSI file for my Windows Desktop Module.
The installation is done in silent mode (not using the installation wizard) using command like

Setup.msi /q /Lv "mylog.txt" 





每做一次更改在代码中,我创建了一个新的设置文件,其中包含更新的程序集号,设置版本号 - 也可以更新产品代码。

另外'检测较新的已安装版本'属性设置为True 。



我遇到了一个安装了设置号为1.1.115并仍然是用户试图安装设置号1.1.114的情况。使用上面的命令。



正如预期的安装失败,因为已经安装了较新版本,但它返回了错误代码,如下所示。









For every change made in the code , i create a new set-up file with updated assembly number, Set-up Version number- which updates product code as well.
Also 'Detect Newer Installed version' property is set to True.

I came across a case where set-up number 1.1.115 is installed and still user tries to install set-up number 1.1.114. using the above command.

As expected installation fails as newer version is already installed but it returned incorrect error code as below.



The install fails because of
MSI (s) (64:08) [10:06:42:216]: Product: "Product name" -- Unable to install because a newer version of this product is already installed.

We are getting error 1603 and I am expecting 1638


ERROR_INSTALL_FAILURE    1603   Fatal error during installation.

I am expecting

ERROR_PRODUCT_VERSION    1638   Another version of this product is already
                                installed. Installation of this version
                                cannot continue. To configure or remove
                                the existing version of this product, use
                                Add/Remove Programs on the Control Panel.





我们总是得到错误代码1603而不是1638.



i用Google搜索但无法得出结论。



如果您以前遇到过这个问题,请告诉我们吗?

我必须在安装项目中做些什么更改才能获得正确的错误代码?



谢谢

Amol



We always get Error Code 1603 instead of 1638.

i did googled for it but could not come to a conclusion.

Experts please let me know if you have faced this issue before?
What changes do i have to make in setup project in order to get correct ERROR CODE?

Thanks
Amol

推荐答案


这篇关于Windows Installer返回不正确的错误代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-21 03:10