简体   繁体   English

C#如何将多个水晶报告打印为一个?

[英]C# how to print multiple crystal reports as one?

I have a report with some parameters that are filled by code, right now the program, load, fill and print the report in a loop 我有一个报告,其中包含一些由代码填充的参数,现在是程序,加载,填充并在循环中打印报告

// get list that contains reports data, every item in list is a report
List<Etiquetas> etiquetas = SolicitudBL.GetEtiquetas(id);
foreach(Etiqueta e in etiquetas)
{
   // load report and pass data
   // report only shows paramaters value, dont use data from database
   ReportDocument report = GetReport("reportName", e);
   report.PrintToPrinter(1, false, 0, 0);
}

this works but takes to much time to print between reports is there a way to print all the reportdocuments at the same time? 这工作但需要花费很多时间在报告之间打印是否有办法同时打印所有报告文档?

The reason why there is a waiting time between the prints is that Crystal needs time to query the database and render each report. 打印之间存在等待时间的原因是Crystal需要时间来查询数据库并呈现每个报告。 You can export the reports to PDFs and then print them. 您可以将报告导出为PDF,然后打印它们。 Total time will be the same , but there will be no big pauses while printing. 总时间相同,但打印时不会有大的暂停。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM