多文档报表查看器 RDLC C#CMR 传输文档

问题描述

我在用 C# 中的 reportviewer 创建多文档(CMR doc)报告时遇到了一些问题。 这是我在同一个报告中包含 2 个数据集的代码,carga_cmr 是一个 List。 CargaCMR 使用一个字段到另一个名为 CuerpoCMR 的类(ComponentesCMR)

        reportCMR.ProcessingMode = ProcessingMode.Local;
        reportCMR.LocalReport.ReportEmbeddedResource = "WindowsFormsApp1.CMR_NEW_2.rdlc";
        
        ReportDataSource rds1 = new ReportDataSource();
        rds1.Value = carga_cmr;
        rds1.Name = "DataSet1";

        ReportDataSource rds2 = new ReportDataSource();
        rds2.Value = carga_cmr[0].ComponentesCMR;
        rds2.Name = "DataSet2";

        reportCMR.LocalReport.DataSources.Clear();
        reportCMR.LocalReport.DataSources.Add(rds1);
        reportCMR.LocalReport.DataSources.Add(rds2);
        reportCMR.RefreshReport();

CMR 运输单据需要 4 份副本,每份副本有 1 次更改。 如何在同一份报告中设置 4 个文档?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)