询问者
使用vs2017打开以前的vs程序,编译出现了报表错误:“未能加载文件或程序集“Microsoft.ReportViewer.WebForms”

问题
-
报错信息
严重性 代码 说明 项目 文件 行 禁止显示状态
错误 未能加载文件或程序集“Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91”或它的某一个依赖项。找到的程序集清单定义与程序集引用不匹配。 (异常来自 HRESULT:0x80131040) D:\develop\business2014\Web.config 24我的web.config定义报表
<add assembly="Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>
<add assembly="Microsoft.ReportViewer.Common, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>vs2017中的nuget也添加了Microsoft.Report.Viewer 11版本和Microsoft.ReportViewer2015 12版本
不知道什么原因还报错
全部回复
-
你好,
使用Nuget 安装一下Microsoft.ReportViewer.2012.Runtime 在试试看能不能解决。
如果问题还在的话,能不能上传一个可以重现问题的Demo, 你可以上传到OneDrive, 然后把链接贴到这里。
Best regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com. -
你好,
可以提供一个简单的可以重新问题的Demo吗?
Best regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com. -
刚才把nuget管理里面,已经安装的报表包全部删除,然后重新安装了一个Microsoft.Report.Viewer 11版本的包,系统编译暂时又好了
谢谢诸位!
- 已建议为答案 Zhanglong WuMicrosoft contingent staff, Moderator 2018年4月13日 8:42
-
你好,
很高兴知道你解决了你的问题,感谢提供相关的解决方案,可以把你的回复 标记为答复吗, 这样有利于其他有相似问题的开发人员。
Best regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.