如何使用Installshield将dll注册到GAC中

时间:2022-11-16 22:40:57

I have installshield 2016 premier and I have a .Net dll that uses a com dll. My application is a plugin so the main exe (its not my exe), is looking mydll in windows even myplugin is in program files. Manually when I use "gacutil.exe -i mydll.dll" it works. Then the dll is not need to be in windows folder.

我有installshield 2016 premier,我有一个使用com dll的.Net dll。我的应用程序是一个插件,所以主要的exe(它不是我的exe),在Windows中看起来mydll甚至myplugin在程序文件中。我使用“gacutil.exe -i mydll.dll”时手动运行。然后dll不需要在Windows文件夹中。

So I tried also regasm but it did not work. So i have to register mydll into gac somehow. The target machine has not gacutil.exe so i cannot call basically from command.

所以我也尝试了regasm,但它没有用。所以我必须以某种方式将mydll注册到gac中。目标机器没有gacutil.exe所以我基本上无法从命令调用。

I looked at how installshield can do that but it did not work as well. I checked "self register" and "com extract at build" yes but did not work and i got an error while installing (because its not a pure com dll, it has only referenced a com dll with embed interop type). When I choose .Net Com Interop settings Yes, then installshield it not build my setup file.

我看了一下installshield如何做到这一点,但它没有起作用。我检查了“自我注册”和“com在构建时提取”但是没有工作,我在安装时遇到错误(因为它不是纯粹的com dll,它只引用了一个带有嵌入式互操作类型的com dll)。当我选择.Net Com Interop设置是,然后installshield它不构建我的安装文件。

So Is there anyway to register this dll during/end of installation?

那么无论如何在安装期间/结束时注册这个dll?

Update: When i do "build and scan dependencies", it cannot find anything!

更新:当我“构建和扫描依赖项”时,它找不到任何东西!

1 个解决方案

#1


0  

Use "Support files" functionality of InstallShiled and place gacUtil or installUtil into "Support files" folder and run the utility at the end of the installation. This may help to solve the problem. This is same like running from command prompt. Refer the link for more details

使用InstallShiled的“支持文件”功能,将gacUtil或installUtil放入“支持文件”文件夹,并在安装结束时运行该实用程序。这可能有助于解决问题。这与从命令提示符运行相同。有关详细信息,请参阅链接

#1


0  

Use "Support files" functionality of InstallShiled and place gacUtil or installUtil into "Support files" folder and run the utility at the end of the installation. This may help to solve the problem. This is same like running from command prompt. Refer the link for more details

使用InstallShiled的“支持文件”功能,将gacUtil或installUtil放入“支持文件”文件夹,并在安装结束时运行该实用程序。这可能有助于解决问题。这与从命令提示符运行相同。有关详细信息,请参阅链接