ClosedXML-无法加载文件或程序集异常 [英] ClosedXML - Could not load file or assembly exception

查看:63
本文介绍了ClosedXML-无法加载文件或程序集异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用ClosedXML在应用程序中生成excel文档,但是,当我尝试运行它时,出现了无法加载文件或汇编服务器的错误.

I am trying to use ClosedXML to produce excel documents within an application, however, Whenevet I try to run it I receive a could not load file or assembly server error.

这是我的表格申请

这是我的包裹

这是我单击导入文件按钮时的错误

and this is my error when I click the import file button

错误

推荐答案

由于您是为SharePoint开发的,因此所有使用的程序集都必须使用强名称.它们已部署在GAC中,仅适用于已签名的程序集.

Since you're developing for SharePoint, all used assemblies need to be strongly-named. They are deployed in the GAC, which is only possible for signed assemblies.

此职位的更多信息: https://sharepoint.stackexchange.com/questions/62242/gac-and-signing-assembly-with-strong-name

您可以将NuGet引用更改为 ClosedXml.Signed ,即ClosedXml的签名版本.

You can change the NuGet reference to be ClosedXml.Signed, the signed version of ClosedXml.

这篇关于ClosedXML-无法加载文件或程序集异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆