应用程序要求先在GAC中安装log4net程序集 [英] Application requires log4net assembly be install in GAC first
问题描述
尝试在我的一台服务器上安装VS2015控制台应用程序时,出现此错误:
试图将dll拖放到程序集文件夹中并显示 Access Denied。
发布前在VS2015中是否需要更改?
问题已解决。
p>首先,我尝试了Nino的回答,但该服务器上未安装gacutil.exe,因此无法运行该cmd。
在Visual Studio 2015属性/发布设置中浏览项目后,在安装模式和设置下,单击应用程序文件...按钮,并确保该dll文件在发布中包含。我需要的dll未包含在内,但包含它之后,重新发布,一切都安装正确。
When trying to install a VS2015 console app onto one of my servers, I get this error:
On another server it installs a runs just fine and the only difference I can see between the two is the the server that it does install on, has two log4net.dll in GAC. One has processor architecture of AMD64 and the other x86. And the server that the program does not install on only has the AMD64 dll. How can I install the x86 version?
I have tried regsvr32 log4net.dll command, but this give me this error:
Tried to drag and drop the dll to the assembly folder and says "Access Denied".
Is there a something I need to change in VS2015 before publishing?
Problem solved.
First I tried the answer from Nino and gacutil.exe is not installed on that server, so I could not run that cmd.
After going through the project in Visual Studio 2015 properties/Publish settings, under Install Mode and settings, click button "Application Files..." and make sure that dll file is "included" in publishing. The dll i needed was not included, but after including it, re-published, everything installed just fine.
这篇关于应用程序要求先在GAC中安装log4net程序集的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!