1

VS セットアップ プロジェクトを使用してインストーラーを生成しています。生成された MSI のバージョンを修正するために、生成された MSI の製品コードとバージョンを変更するスクリプトがあります。

以前のバージョンの MSI をインストールしましたが、新しいバージョンをインストールしようとすると (セットアップ プロジェクトに "RemovePreviousVersions = true" があります)、"この製品の新しいバージョンが既にインストールされています" というメッセージが表示され、インストールが失敗します。

新しいバージョンの方が実際にバージョン番号が大きく (3.910.5377 対 3.901.5374)、製品 GUID が異なることを確認しました。

何がこの失敗を引き起こす可能性がありますか?

以下は注入ログです。

=== Logging started: 21/09/2014  11:33:59 ===
Action start 11:33:59: INSTALL.
Action start 11:33:59: DIRCA_CheckFX.
INFO   : [09/21/2014 11:33:59:708] [CheckFX                                 ]: Custom Action is starting...
INFO   : [09/21/2014 11:33:59:709] [CheckFX                                 ]: CoInitializeEx - COM initialization Apartment Threaded...
INFO   : [09/21/2014 11:33:59:710] [CheckFX                                 ]: MsiGetPropertyW - Determine size of property 'VSDFrameworkVersion'
INFO   : [09/21/2014 11:33:59:710] [CheckFX                                 ]: Allocating space...
INFO   : [09/21/2014 11:33:59:710] [CheckFX                                 ]: MsiGetPropertyW - Getting Property 'VSDFrameworkVersion'...
INFO   : [09/21/2014 11:33:59:711] [CheckFX                                 ]: Property 'VSDFrameworkVersion'  retrieved with value 'v4.0'.
INFO   : [09/21/2014 11:33:59:711] [CheckFX                                 ]: MsiGetPropertyW - Determine size of property 'VSDFrameworkProfile'
INFO   : [09/21/2014 11:33:59:711] [CheckFX                                 ]: Allocating space...
INFO   : [09/21/2014 11:33:59:711] [CheckFX                                 ]: MsiGetPropertyW - Getting Property 'VSDFrameworkProfile'...
INFO   : [09/21/2014 11:33:59:711] [CheckFX                                 ]: Property 'VSDFrameworkProfile'  retrieved with value 'Client'.
INFO   : [09/21/2014 11:33:59:712] [CheckFX                                 ]: Set VSDNETMSG with the FrameworkVersion.
INFO   : [09/21/2014 11:33:59:712] [CheckFX                                 ]: MsiGetPropertyW - Determine size of property 'VSDNETMSG'
INFO   : [09/21/2014 11:33:59:712] [CheckFX                                 ]: Allocating space...
INFO   : [09/21/2014 11:33:59:712] [CheckFX                                 ]: MsiGetPropertyW - Getting Property 'VSDNETMSG'...
INFO   : [09/21/2014 11:33:59:712] [CheckFX                                 ]: Property 'VSDNETMSG'  retrieved with value 'This setup requires the .NET Framework version [1].  Please install the .NET Framework and run this setup again.'.
INFO   : [09/21/2014 11:33:59:713] [CheckFX                                 ]: MsiSetPropertyW - Setting Property Value...
INFO   : [09/21/2014 11:33:59:713] [CheckFX                                 ]: MsiSetPropertyW - Setting property 'VSDNETMSG' to 'This setup requires the .NET Framework version 4.0.  Please install the .NET Framework and run this setup again.'.
INFO   : [09/21/2014 11:33:59:713] [CheckFX                                 ]: MsiGetPropertyW - Determine size of property 'VSDNETURLMSG'
INFO   : [09/21/2014 11:33:59:713] [CheckFX                                 ]: Allocating space...
INFO   : [09/21/2014 11:33:59:714] [CheckFX                                 ]: MsiGetPropertyW - Getting Property 'VSDNETURLMSG'...
INFO   : [09/21/2014 11:33:59:714] [CheckFX                                 ]: Property 'VSDNETURLMSG'  retrieved with value 'This setup requires the .NET Framework version [1].  Please install the .NET Framework and run this setup again.  The .NET Framework can be obtained from the web.  Would you like to do this now?'.
INFO   : [09/21/2014 11:33:59:714] [CheckFX                                 ]: MsiSetPropertyW - Setting Property Value...
INFO   : [09/21/2014 11:33:59:714] [CheckFX                                 ]: MsiSetPropertyW - Setting property 'VSDNETURLMSG' to 'This setup requires the .NET Framework version 4.0.  Please install the .NET Framework and run this setup again.  The .NET Framework can be obtained from the web.  Would you like to do this now?'.
INFO   : [09/21/2014 11:33:59:715] [CheckFX                                 ]: MsiSetPropertyW - Setting Property Value...
INFO   : [09/21/2014 11:33:59:715] [CheckFX                                 ]: MsiSetPropertyW - Setting property 'VSDFXAvailable' to 'TRUE'.
INFO   : [09/21/2014 11:33:59:715] [CheckFX                                 ]: Writing config file with version: '4.0'...
INFO   : [09/21/2014 11:33:59:716] [CheckFX                                 ]: Creating Config File...
DEBUG  : [09/21/2014 11:33:59:716] [CheckFX                                 ]: Calling MsiGetActiveDatabase...
DEBUG  : [09/21/2014 11:33:59:716] [CheckFX                                 ]: Calling MsiDatabaseOpenView...
DEBUG  : [09/21/2014 11:33:59:717] [CheckFX                                 ]: Calling MsiViewExecute...
DEBUG  : [09/21/2014 11:33:59:717] [CheckFX                                 ]: Calling MsiViewFetch...
DEBUG  : [09/21/2014 11:33:59:717] [CheckFX                                 ]: Calling MsiRecordDataSize...
INFO   : [09/21/2014 11:33:59:718] [CheckFX                                 ]: MsiSetPropertyW - Setting Property Value...
INFO   : [09/21/2014 11:33:59:718] [CheckFX                                 ]: MsiSetPropertyW - Setting property 'VSDFxConfigFile' to 'C:\Users\OREN~1.RE-\AppData\Local\Temp\CFG8BB2.tmp'.
INFO   : [09/21/2014 11:33:59:718] [CheckFX                                 ]: Custom Action succeeded.
INFO   : [09/21/2014 11:33:59:719] [CheckFX                                 ]: Custom Action completed with return code: '0'
Action ended 11:33:59: DIRCA_CheckFX. Return value 1.
Action start 11:33:59: AppSearch.
Action ended 11:33:59: AppSearch. Return value 1.
Action start 11:33:59: FindRelatedProducts.
Action ended 11:33:59: FindRelatedProducts. Return value 1.
Action start 11:33:59: ERRCA_CANCELNEWERVERSION.
MSI (s) (88:FC) [11:33:59:723]: Product: MyProd -- Unable to install because a newer version of this product is already installed.

Unable to install because a newer version of this product is already installed.
Action ended 11:33:59: ERRCA_CANCELNEWERVERSION. Return value 3.
Action ended 11:33:59: INSTALL. Return value 3.
Property(S): UpgradeCode = {695EE149-3040-435B-BF0D-F57C3053ECA6}
Property(S): DesktopFolder = C:\Users\oren.company\Desktop\
Property(S): ProgramMenuFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\
Property(S): VSDFXAvailable = TRUE
Property(S): VSDFrameworkVersion = v4.0
Property(S): VSDFrameworkProfile = Client
Property(S): VSDAllowLaterFrameworkVersions = False
Property(S): SERVERADDRESS = oren-pc
Property(S): ProductName = MyProd
Property(S): ProductCode = {d46578ca-87f8-4335-90b9-bc362b8bd367}
Property(S): ProductVersion = 3.910.5377
Property(S): Manufacturer = XXX
Property(S): ARPCONTACT = XXX
Property(S): ARPURLINFOABOUT = www.company.com
Property(S): ProductLanguage = 1033
Property(S): ARPPRODUCTICON = _853F67D554F05449430E7E.exe
Property(S): SecureCustomProperties = PREVIOUSVERSIONSINSTALLED;NEWERPRODUCTFOUND
Property(S): NEWERPRODUCTFOUND = {f13569d9-45f2-45b7-b766-4816a93c1d87}
Property(S): RedirectedDllSupport = 2
Property(S): VersionNT = 601
Property(S): VSDNETURLMSG = This setup requires the .NET Framework version 4.0.  Please install the .NET Framework and run this setup again.  The .NET Framework can be obtained from the web.  Would you like to do this now?
Property(S): VSDIISMSG = This setup requires Internet Information Server 5.1 or higher and Windows XP or higher.  This setup cannot be installed on Windows 2000.  Please install Internet Information Server or a newer operating system and run this setup again.
Property(S): VSDUIANDADVERTISED = This advertised application will not be installed because it might be unsafe. Contact your administrator to change the installation user interface option of the package to basic.
Property(S): VSDNETMSG = This setup requires the .NET Framework version 4.0.  Please install the .NET Framework and run this setup again.
Property(S): VSDINVALIDURLMSG = The specified path '[2]' is unavailable. The Internet Information Server might not be running or the path exists and is redirected to another machine. Please check the status of this virtual directory in the Internet Services Manager.
Property(S): VSDVERSIONMSG = Unable to install because a newer version of this product is already installed.
Property(S): AdminMaintenanceForm_Action = Repair
Property(S): DefaultUIFont = VsdDefaultUIFont.524F4245_5254_5341_4C45_534153783400
Property(S): ErrorDialog = ErrorDialog
Property(S): SFF_UpFldrBtn = UpFldrBtn
Property(S): SFF_NewFldrBtn = NewFldrBtn
Property(S): EDITA4 = 1
Property(S): EDITA3 = 1
Property(S): EDITA2 = 1
Property(S): EDITA1 = 1
Property(S): EulaForm_Property = No
Property(S): MaintenanceForm_Action = Repair
Property(S): CustomTextA_NextArgs = EulaForm
Property(S): EulaForm_PrevArgs = CustomTextA
Property(S): EulaForm_NextArgs = WelcomeForm
Property(S): WelcomeForm_PrevArgs = EulaForm
Property(S): WelcomeForm_NextArgs = ConfirmInstallForm
Property(S): ConfirmInstallForm_PrevArgs = WelcomeForm
Property(S): AdminWelcomeForm_NextArgs = AdminFolderForm
Property(S): AdminFolderForm_PrevArgs = AdminWelcomeForm
Property(S): AdminFolderForm_NextArgs = AdminConfirmInstallForm
Property(S): AdminConfirmInstallForm_PrevArgs = AdminFolderForm
Property(S): MsiLogFileLocation = C:\Users\oren.company\AppData\Local\Temp\msi1.log
Property(S): PackageCode = {240303AC-B280-41A4-BB80-E82DD274E006}
Property(S): ProductState = -1
Property(S): PackagecodeChanging = 1
Property(S): REBOOT = ReallySuppress
Property(S): CURRENTDIRECTORY = C:\Users\oren.company\AppData\Local\Temp
Property(S): CLIENTUILEVEL = 3
Property(S): CLIENTPROCESSID = 1276
Property(S): MsiRestartManagerSessionKey = 866e59d34f5b104a9d87126a30675d33
Property(S): MsiSystemRebootPending = 1
Property(S): VersionDatabase = 200
Property(S): VersionMsi = 5.00
Property(S): VersionNT64 = 601
Property(S): WindowsBuild = 7601
Property(S): ServicePackLevel = 1
Property(S): ServicePackLevelMinor = 0
Property(S): MsiNTProductType = 1
Property(S): WindowsFolder = C:\Windows\
Property(S): WindowsVolume = C:\
Property(S): System64Folder = C:\Windows\system32\
Property(S): SystemFolder = C:\Windows\SysWOW64\
Property(S): RemoteAdminTS = 1
Property(S): TempFolder = C:\Users\OREN~1.RE-\AppData\Local\Temp\
Property(S): ProgramFilesFolder = C:\Program Files (x86)\
Property(S): CommonFilesFolder = C:\Program Files (x86)\Common Files\
Property(S): ProgramFiles64Folder = C:\Program Files\
Property(S): CommonFiles64Folder = C:\Program Files\Common Files\
Property(S): AppDataFolder = C:\Users\oren.company\AppData\Roaming\
Property(S): FavoritesFolder = C:\Users\oren.company\Favorites\
Property(S): NetHoodFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Network Shortcuts\
Property(S): PersonalFolder = C:\Users\oren.company\Documents\
Property(S): PrintHoodFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Printer Shortcuts\
Property(S): RecentFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Recent\
Property(S): SendToFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\SendTo\
Property(S): TemplateFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Templates\
Property(S): CommonAppDataFolder = C:\ProgramData\
Property(S): LocalAppDataFolder = C:\Users\oren.company\AppData\Local\
Property(S): MyPicturesFolder = C:\Users\oren.company\Pictures\
Property(S): AdminToolsFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Administrative Tools\
Property(S): StartupFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\
Property(S): StartMenuFolder = C:\Users\oren.company\AppData\Roaming\Microsoft\Windows\Start Menu\
Property(S): FontsFolder = C:\Windows\Fonts\
Property(S): GPTSupport = 1
Property(S): OLEAdvtSupport = 1
Property(S): ShellAdvtSupport = 1
Property(S): MsiAMD64 = 6
Property(S): Msix64 = 6
Property(S): Intel = 6
Property(S): PhysicalMemory = 7783
Property(S): VirtualMemory = 8854
Property(S): AdminUser = 1
Property(S): MsiTrueAdminUser = 1
Property(S): LogonUser = oren
Property(S): UserSID = S-1-5-21-2662074009-2945771039-325267052-1127
Property(S): UserLanguageID = 1037
Property(S): ComputerName = OREN-PC
Property(S): SystemLanguageID = 1033
Property(S): ScreenX = 1024
Property(S): ScreenY = 768
Property(S): CaptionHeight = 22
Property(S): BorderTop = 1
Property(S): BorderSide = 1
Property(S): TextHeight = 16
Property(S): TextInternalLeading = 3
Property(S): ColorBits = 32
Property(S): TTCSupport = 1
Property(S): Time = 11:33:59
Property(S): Date = 9/21/2014
Property(S): MsiNetAssemblySupport = 4.0.30319.18408
Property(S): MsiWin32AssemblySupport = 6.1.7601.17514
Property(S): MsiRunningElevated = 1
Property(S): Privileged = 1
Property(S): USERNAME = oren
Property(S): DATABASE = C:\Windows\Installer\4858a8a.msi
Property(S): OriginalDatabase = C:\Windows\TEMP\MyProd.msi
Property(S): UILevel = 2
Property(S): ACTION = INSTALL
Property(S): VSDFxConfigFile = C:\Users\OREN~1.RE-\AppData\Local\Temp\CFG8BB2.tmp
MSI (s) (88:FC) [11:33:59:733]: Product: MyProd -- Installation failed.

MSI (s) (88:FC) [11:33:59:734]: Windows Installer installed the product. Product Name: MyProd. Product Version: 3.910.5377. Product Language: 1033. Manufacturer: XXX. Installation success or error status: 1603.

=== Logging stopped: 21/09/2014  11:33:59 ===
4

2 に答える 2

3

あなたのスクリプトは正しくありません :) ビルド中の MSI の PackageCode も変更する必要があります。これは、IDE を使用してバージョンを変更するときに VS が目に見えないことを行います。

于 2014-09-21T18:20:50.563 に答える
1

これは、 ProductVersion プロパティの 2 番目のフィールドに不適切な値を使用しているために発生する可能性があります。ProductVerison プロパティの最大値は255.255.65535です。

于 2014-09-22T11:53:31.397 に答える