本文介绍了威克斯想要一个组装清单-我有一个的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经创建了一个C#CustomActions项目,可以在wix中使用它来创建安装程序。我所拥有的只是一个示例项目和一个引用它的示例wix项目。然后我在C#项目中创建了一个app.manifest。

I have created a C# CustomActions project to use in wix to create an installer. All I have is the sample project and a sample wix project that references it. And I created an app.manifest in the C# project.

我得到的是:

1>------ Build started: Project: SetupProject1, Configuration: Debug x86 ------
1>      C:\Program Files (x86)\WiX Toolset v3.11\bin\candle.exe -dDebug -d"DevEnvDir=C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\\" -dSolutionDir=C:\src\WixTest\ -dSolutionExt=.sln -dSolutionFileName=WixTest.sln -dSolutionName=WixTest -dSolutionPath=C:\src\WixTest\WixTest.sln -dConfiguration=Debug -dOutDir=bin\Debug\ -dPlatform=x86 -dProjectDir=C:\src\SetupProject1\ -dProjectExt=.wixproj -dProjectFileName=SetupProject1.wixproj -dProjectName=SetupProject1 -dProjectPath=C:\src\SetupProject1\SetupProject1.wixproj -dTargetDir=C:\src\SetupProject1\bin\Debug\ -dTargetExt=.msi -dTargetFileName=SetupProject1.msi -dTargetName=SetupProject1 -dTargetPath=C:\src\SetupProject1\bin\Debug\SetupProject1.msi -out obj\Debug\ -arch x86 -ext ..\WixTest\bin\Debug\WixTest.CA.dll Product.wxs
1>candle.exe(0,0): error CNDL0144: The extension '..\WixTest\bin\Debug\WixTest.CA.dll' could not be loaded because of the following reason: Could not load file or assembly 'file:///C:\src\WixTest\bin\Debug\WixTest.CA.dll' or one of its dependencies. The module was expected to contain an assembly manifest.
1>Done building project "SetupProject1.wixproj" -- FAILED.
1>

========== Build:0成功,1失败,1 up-到目前为止,已跳过0 ==========

========== Build: 0 succeeded, 1 failed, 1 up-to-date, 0 skipped ==========

还有其他需要做什么吗?

Any idea what else I need to do?

推荐答案

是的,我看过了-请尝试以下操作:

Yes, I had a look - please try this:


  1. 请删除对 WixTestCA 的引用,在其中保留 WixTest 。您不需要直接引用WixTestCA文件。您需要一个项目引用。

  2. 将公司名称或其他内容(将执行任何操作)添加到属性 Manufacturer

  3. 在自定义元素中添加 After ='InstallInitialize' ,以指示在

  1. Please remove the reference to WixTestCA, leave WixTest in there. You don't need a direct reference to the WixTestCA file. You need a project reference instead.
  2. Add your company name or something (anything will do) to the attribute Manufacturer.
  3. Add After='InstallInitialize' to the Custom element to indicate scheduling inside the InstallExecuteSequence for the custom action in question.

以下是注入了更改的代码片段:

Here are the snippets with injected changes:

产品元素

The Product element:

<Product Id="*" Name="SetupProject1" Language="1033" Version="1.0.0.0" Manufacturer="Add Company Name here" UpgradeCode="ADD-VALID-GUID-HERE">

自定义元素 (自定义操作):

The Custom element (custom action):

<Custom Action='LicenseInfoCustomAction' After='InstallInitialize'>NOT Installed</Custom>

这篇关于威克斯想要一个组装清单-我有一个的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-23 23:11