简体   繁体   English

Installshield 2013合并模块+ WIX C#自定义操作项目

[英]Installshield 2013 Merge Module + WIX C# Custom Action Project

My End Goal: write a merge module in Installshield 2013 that can find a xml file on disk and modify it. 我的最终目标:在Installshield 2013中编写一个合并模块,该模块可以在磁盘上找到xml文件并对其进行修改。 Finding the file requires using a 3rd party interop to query for the location of the file. 查找文件需要使用第三方互操作来查询文件的位置。 This is because the file is installed by another product. 这是因为文件是由另一产品安装的。

I've tried a few things: 我已经尝试了几件事:

  • Using the Sample Managed Class Library DLL's provided with Installshield. 使用Installshield提供的示例托管类库DLL。 This works well until the 3rd party classes are used in the code. 在代码中使用第三方类之前,此方法效果很好。

  • Using the WIX C# Custom Action Project : As far as I can see, there is no option to add the standard DLL to a merge module only a MSI in Installshield. 使用WIX C#自定义操作项目:据我所知,没有选择将标准DLL添加到合并模块中的选项,只有Installshield中的MSI。 Correct me if I am wrong. 如果我错了,请纠正我。

Questions: 问题:

  • What is the best way to achieve this functionality using Installshield? 使用Installshield实现此功能的最佳方法是什么?
  • Can I install my C# dll as well as the needed Interop before calling the custom action in my DLL? 在DLL中调用自定义操作之前,可以安装C#dll以及所需的Interop吗? Would that be a good approach? 那会是个好方法吗?

Any suggestion would be greatly appreciated. 任何建议将不胜感激。

Third party assemblies can be included in an InstallShield Managed Code Custom Action, but it involves editing the IsClrWrap table to list the dependencies (the link points to a doc file). 第三方程序集可以包含在InstallShield托管代码自定义操作中,但是它涉及编辑IsClrWrap表以列出依赖关系 (链接指向doc文件)。

If you instead use a WiX DTF action, it generates what InstallShield calls an MSI DLL, as the entry points are callable directly by MSI. 如果改用WiX DTF操作,则它将生成InstallShield称为MSI DLL的内容,因为入口点可由MSI直接调用。 You don't have to use the "Standard DLL" wrapper functionality. 您不必使用“标准DLL”包装器功能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM