List<ReportDataInfo> Lrdi = new List<ReportDataInfo>(); ReportDataInfo rdi = new ReportDataInfo(); ReportDataInfo RdiMerge=new ReportDataInfo(); string[] AccountTypeCodeCustomArray = AccountCodeTypeCustom.Split(",".tochararray()); string[] SubTypeCodeCustomArray = SubAccountTypeCodeCustom.Split(",".tochararray()); string[] AccountCodeCustomArray = AccountCodeCustom.Split(",".tochararray()); for (int i = 0; i < AccountCodeTypeCustom.Length; i++) { rdi = ExportDataToCSV.GetLedgerReportData(Globals.GetInt( AccountTypeCodeCustomArray[i],0),Globals.GetInt( SubTypeCodeCustomArray[i],Globals.GetInt( AccountCodeCustomArray[i],this.CurrentSessionInfo.Company.CompanyCode,this.CurrentSessionInfo.FinancialYear.StartDate,this.CurrentSessionInfo.FinancialYear.EndDate); // Lrdi.Add(rdi); RdiMerge.Rows.Concat(rdi.Rows); //RdiMerge.Reportheading = rdi.Reportheading; //RdiMerge.Rows = rdi.Rows; } CurrentSessionInfo.ReportData = RdiMerge;
这是我以前尝试过的事情
现在我的问题是
我希望从ExportDataToCSV.GetLedgerReportData()返回合并返回的ReportDataInfo;
无论从ExportDataToCSV.GetLedgerReportData()返回什么值,我都被困在这里;
我想合并到单个ReportDataInfo然后传递给CurrentSessionInfo.ReportData = RdiMerge;
ReportDataInfolooks之类的
[Serializable] public class ReportDataInfo { public string Reportheading { get; set; } public List<ReportColumnInfo> Rows { get; set; } }
解决方法
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。