arg*_*yle 10 .net reportviewer
我在Windows服务应用程序中遇到以下异常:
System.IO.FileNotFoundException:无法加载文件或程序集"Microsoft.ReportViewer.Common,Version = 12.0.0.0,Culture = neutral,PublicKeyToken = 89845dcd8080cc91"或其依赖项之一.该系统找不到指定的文件.
我找不到版本12的下载URL并将文件设置为"Include"和"Prequisite(Auto)"并不能解决此Windows服务应用程序中的问题,尽管它在我的WinForms应用程序中工作正常并导致相应的文件存在包含和引用以及所有其他必需的.DLL.
有人可以帮助我获取此Windows服务应用程序以包含文件,或者引导我到将在GAC中安装版本12的下载链接吗?
Dav*_*sey 40
ReportViewer位的第12版称为Microsoft Report Viewer 2015 Runtime,可以从以下链接下载以进行安装:
https://www.microsoft.com/en-us/download/details.aspx?id=45496
更新:
ReportViewer位也可以作为NUGET包使用:https://www.nuget.org/packages/Microsoft.ReportViewer.Runtime.Common/12.0.2402.15
Install-Package Microsoft.ReportViewer.Runtime.Common
I worked on this issue for a few days. Installed all packages, modified web.config and still had the same problem. I finally removed
<assemblies>
<add assembly="Microsoft.ReportViewer.Common, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
</assemblies>
Run Code Online (Sandbox Code Playgroud)
from the web.config and it worked. No exactly sure why it didn't work with the tags in the web.config file. My guess there is a conflict with the GAC and the BIN folder.
Here is my web.config file:
<?xml version="1.0"?>
<configuration>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
<httpHandlers>
<add verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
</httpHandlers>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
<handlers>
<add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
</handlers>
</system.webServer>
</configuration>
Run Code Online (Sandbox Code Playgroud)
在 IIS 服务器 PC 上部署后,我收到此错误。
https://www.microsoft.com/en-us/download/details.aspx?id=42295在此处输入链接描述
https://www.microsoft.com/en-us/download/details.aspx?id=45496
它可能需要重新启动您的计算机。
| 归档时间: |
|
| 查看次数: |
91947 次 |
| 最近记录: |