System.MissingMethodException 方法未找到 Crystal Reports [英] System.MissingMethodException Method Not Found Crystal Reports

查看:27
本文介绍了System.MissingMethodException 方法未找到 Crystal Reports的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试更新应用程序时,我在客户端工作站上遇到以下异常:

I'm running into the following exception on my client workstation when trying to update the application:

System.MissingMethodException: 
Method not found: 'Void CrystalDecisions.Windows.Forms.CrystalReportViewer.set_CachedPageNumberPerDoc(Int32)'.
at OpusRw.CrystalReports.CryRepView.InitializeComponent()
at OpusRw.CrystalReports.CryRepView..ctor() in   
   c:cli_codeOPUSfinOPUSfinCrystalReportsCryRepView.cs:line 21
   at OPUSfin.SubForms.PrintScreen.btInsertion_Click(Object sender, EventArgs e) in  
   c:cli_codeOPUSfinOPUSfinSubFormsPrintScreen.cs:line 55

但是,当我在本地调试代码时,我没有问题.(更新甚至没有改变相关代码).

However when I debug the code locally I have no problem. (The updates did not even alter the code in question).

我最初认为这是一个 .dll 错误,并尝试清理解决方案,删除并重新添加 .dll 无济于事.

I initially assumed this was a .dll error and Have tried cleaning the solution, removing and re-adding the .dll's to no avail.

我还可以尝试哪些其他方法来解决此问题?

What other things can I try to resolve the issue ?

推荐答案

我用vb编程,遇到了类似的问题.有一个带有许多屏幕/表单的 vb.net 应用程序,每个屏幕/表单都有一个 CrystalReportViewr (crv).7/2014 之前开发的屏幕工作正常.之后开发的那些不会加载并得到错误:'无效 CrystalDecisions.Windows.Forms.CrystalReportViewer.set_CachedPageNumberPerDoc(Int32)'.解决方案:打开解决方案资源管理器".转到有问题的表格并展开+"号.右键单击 YourFormName.Designer.vb 并选择查看代码".在生成的代码窗口中滚动以找到 CrystalReportViewer 的名称.注释掉一行:Me.crv1.CachedPageNumberPerDoc = 10".

I program in vb and had a similar issue. Have a vb.net app with many screens/forms each with a CrystalReportViewr (crv). Screens developed prior to 7/2014 work fine. Those developed after wouldn't load and got the error: 'Void CrystalDecisions.Windows.Forms.CrystalReportViewer.set_CachedPageNumberPerDoc(Int32)'. Solution: Open 'SolutionExplorer'. Go to form in question and expand the '+' sign. Right click on YourFormName.Designer.vb and choose 'View Code'. In resultant code window scroll to find the name of the CrystalReportViewer. Comment out line: "Me.crv1.CachedPageNumberPerDoc = 10".

我在用户的机器上重新编译和更新了应用程序,它运行正常.

I recompiled and updated the app on user's machines and it worked.

这篇关于System.MissingMethodException 方法未找到 Crystal Reports的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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