Tag: crystal reports

抑制列并删除水晶报告中的空白区域

我正在使用Microsoft Visual Studio 2003。 我正在寻找一种方法来抑制列是否为空,并替换其他列留下的空白。 我到处搜索,但找不到与2003版本兼容的方法。 存在一种简单的方法吗? 我感谢任何帮助。

无打印机选择对话框打印

我想直接打印我的水晶报告,没有打印机选择弹出窗口。 我怎样才能做到这一点 ? myReportDocument.SetDataSource(saveDataSet); //Print crystalReportViewer1.ShowRefreshButton = false; crystalReportViewer1.ShowCloseButton = false; crystalReportViewer1.ShowGroupTreeButton = false; crystalReportViewer1.ReportSource = myReportDocument; crystalReportViewer1.PrintReport(); 我正在使用默认(且仅限)打印机。

CrystalReport加载报告失败

我有一个使用Crystal Report 2008的Windows应用程序项目(C#和.NET 2.0)。但是在加载报告时有时会出现错误(似乎是偶然的)。 那个错误是: CrystalDecisions.Shared.CrystalReportsException: Load report failed. System.Runtime.InteropServices.COMException (0x8000020D): Unable to load report. at CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocumentClass.Open(Object& DocumentPath, Int32 Options) at CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.Open(Object& DocumentPath, Int32 Options) at CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() — End of inner exception stack trace — at CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob) at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename) at SIA.DataTransfer.Forms.frmReport.GetStateReport(Int32 transferType) 请指导我。 我怎么解决这个问题?

将参数传递给C#中的水晶报表

我一直试图让它工作一段时间,我见过的所有示例代码都没有做我正在做的事情。 我有一个程序,它返回我传递数据表的报告的pdf。 这工作正常,除了我想传递几个其他参数(表的日期范围,统计等),我只是无法让它工作。 我的代码基本上是这样的。 ReportDocument myDataReport = new CrystalDecisions.CrystalReports.Engine.ReportDocument(); myDataReport.Load(@”C:\Layouts\Report.rpt”); ParameterField myParam = new ParameterField(); ParameterDiscreteValue myDiscreteValue = new ParameterDiscreteValue(); myParam.ParameterFieldName = “MyParameter”; myDiscreteValue.Value = “Hello”; myParam.CurrentValues.Add(myDiscreteValue); myDataReport.ParameterFields.Add(myParam); myDataReport.SetDataSource(myDataTable); Stream returnData = myDataReport.ExportToStream(PortableDocFormat); myDataReport.Close(); return returnData; 我在rpt文档中添加了参数字段,我需要在c#中更改xsd文件中的任何内容,还是我错过了一些完全不同的东西? 非常感谢,安迪。

Crystal Report不显示在使用VS 2013构建的ASP.net网页中

我正在使用ASP.NET开发一个网站,我想在我的webform中显示一个报告。 我使用水晶报告作为我的报告工具。 我使用visual studio 2013作为我的IDE。 这就是我所尝试过的。 (我的SAP版本是13.0.9)。 private void loadReport() { ReportDocument rpt = new ReportDocument(); rpt.Load(“D:\\Report_Test.rpt”); rpt.VerifyDatabase(); CrystalReportViewer1.ReportSource = rpt; } 上面的代码适用于visual studio 2010但不适用于2013.当我加载页面时,它是空的。 没有丢失任何错误。 那么,如何使用Visual Studio 2013查看Crystal Report?

如何在C#中将SQL Server Compact Edition数据库连接到Crystal Report

我正在尝试将我的SQL Server Compact Edition数据库连接到Crystal Report。 我一整天都在搜索,到目前为止我在其他网站上发现了许多与之相关的问题,但没有一个有可靠的答案。 我也在这个网站上发现了这个问题 ,要求提供VB.Net解决方案。 这个链接遍布互联网,并且有一种令人困惑的方式来通过XML来实现,我无法弄明白。 SQL Server和Access中的解决方案还有其他链接没有帮助。 SQL Server解决方案 访问解决方案 我想知道是否有一种简单的方法将SQL Server CE数据库连接到Crystal Report实际上有效?

对于64位计算机,Crystal Report无法打开

我的报告在32位机器上工作正常但不会在64位上打开。 需要64位,因为在其中一个屏幕上加载数据会导致内存问题 – 因此无法在32位上运行。 Windows 10 64位 已安装的Crystal Reports 尝试安装13.0.20(最新)并重新启动PC但没有工作。 应用程序目标框架4.6.2(我甚至尝试过4.0但同样的错误) 使用Visual Studio 2017社区(尝试VS 2015) 平台x64(不是AnyCPU) 通过传递DataTable生成报告,报告中没有活动连接或ConnectionString 错误信息 编辑#1 Web.config包含useLegacyV2RuntimeActivationPolicy=”true” x86和x64中的DataTable是相同的 编辑#2 显示报告的源代码是 CrystalDecisions.CrystalReports.Engine.ReportClass c = new CrystalDecisions.CrystalReports.Engine.ReportClass(); c.FileName = System.IO.Path.Combine(Root_Path, “Reports”, “Prod”, mFileName); c.Load(); c.SetDataSource(dt); // dt => DataTable c.SetParameterValue(“prmSystemDate”, Current_Date); frmReportViewer v = new frmReportViewer(); v.ReportClass = c; v.Show(); 而frmReportViewer FormLoad是 private void […]

无法加载文件或程序集CrystalDecisions.ReportAppServer.ClientDoc

我在SO上看过类似的问题,但据我所知,没有什么能与我的问题相提并论。 exception消息: 无法加载文件或程序集“CrystalDecisions.ReportAppServer.ClientDoc,Version = 13.0.2000.0,Culture = neutral,PublicKeyToken = 692fbea5521e1304”或其中一个依赖项。 该系统找不到指定的文件。 该文件在我的GAC中。 我正在开发运行VS2010的32位机器(Windows 7),一切都是.NET4。 目标托管机器是64位Win 2008 R2。 我的本地机器有VS2010的CR安装; 托管机器具有VS2010的64位运行时。 我正在为此Web应用程序的“任何CPU”模式编译我的所有代码。 我在想它无法在GAC中找到该文件。 这是一个IIS应用程序; 是否存在某种权限问题? 我认为IIS可以访问GAC。 关于该做什么的一些建议将不胜感激。

使用Visual Studio 2013的Crystal Report aspnet_client / system_web / 4_6_81

我对使用Visual Studio 2013的SAP Crystal Report的行为感到困惑。当我运行ASP.NET Web应用程序时,我得到以下文件夹路径aspnet_client / system_web / 4_6_81 / crystalreportviewers13 /而不是C:\ inetpub \ wwwroot的\ aspnet_client \ system_web \ 4_0_30319 \ crystalreportviewers13。 我在IIS 7.5 C中找不到任何此类文件夹:\ inetpub \ wwwroot \ aspnet_client \ system_web) 。 你能帮帮我吗? 由于这个原因,我无法看到报告。 请查看以下屏幕截图以获取参考

将多个对象设置为水晶报表的数据源

我想在我的c#windows应用程序中制作一个水晶报告,关键是我想使用.net对象作为我的报告数据源,我在互联网上找到它的示例代码如下并使用它们并且它工作正常: ArrayList Mainlst = new ArrayList(); Mainlst.Add(new testOBJ { Firstname = “test1”, Lastname = “test11” }); Mainlst.Add(new testOBJ { Firstname = “test2”, Lastname = “test21” }); Mainlst.Add(new testOBJ { Firstname = “test3”, Lastname = “test31” }); Mainlst.Add(new testOBJ { Firstname = “test4”, Lastname = “test41” }); Mainlst.Add(new testOBJ { Firstname = “test5”, Lastname = “test51” […]