RDLC - 在 AspDotNet Core 项目中使用 RDLC - 本地报告处理期间发生错误。索引超出了数组范围

问题描述 投票:0回答:2

如何修复:在 AspNet Core 项目中使用 RLDC 和 AspNetCore.ReportingServices 会引发异常,如下所示 “本地报告处理期间发生错误。索引超出数组范围。”

  1. 我有.Net Winforms项目来添加RDLC文件。我总是在 AspNet Core 项目中复制/粘贴 rdlc 文件 + 数据源。
  2. 尝试导出 pdf/excel 并抛出上述异常。

注意:这是随机的。它有时会到来。但部署在IIS服务器上时经常出现这种情况。任何建议/建议或帮助将不胜感激。

异常:异常位于我们包含在 DontNetCore 项目中的 AspNetCore.ReportingServices nuget 包中。这是堆栈跟踪。

“在AspNetCore.Reporting.InternalLocalReport.InternalRender(字符串格式,布尔值allowInternalRenderers,字符串deviceInfo,PageCountMode pageCountMode,CreateAndRegisterStream createStreamCallback,警告[]&警告) 在 AspNetCore.Reporting.InternalLocalReport.InternalRender(字符串格式,布尔值allowInternalRenderers,字符串deviceInfo,PageCountMode pageCountMode,字符串和mimeType,字符串和编码,字符串和文件名扩展,字符串[]和流,警告[]和警告) 在 AspNetCore.Reporting.InternalLocalReport.Render(字符串格式,字符串 deviceInfo,PageCountMode pageCountMode,字符串&mimeType,字符串&编码,字符串&fileNameExtension,字符串[]&流,警告[]&警告) 在 AspNetCore.Reporting.LocalReport.Execute(RenderType renderType, Int32 pageIndex, Dictionary

2 parameters, String findString) at Tracs4Life.Service.ReportService.<GenerateReportAsync>d__21.MoveNext() in C:\D drive\MySpace\CompanyProjects\BsiTracks4Life\Source\Tracs4Life\Tracs4Life.Service\ReportService.cs:line 572 at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter
1.GetResult() 在 C:\D 驱动器\MySpace\CompanyProjects\BsiTracks4Life\Source\Tracs4Life\Tracs4Life.Website\Controllers\ReportController.cs 中的 Tracs4Life.Website.Controllers.ReportController.d__11.MoveNext():第 211 行。

asp.net-core reporting rdlc
2个回答
0
投票

请勿使用任何表达式,报告将失败。 这是这个库的限制


0
投票

是的,我也面临同样的问题,添加一个表达式会导致问题。我们如何解决这个问题,因为我需要表达式在报告中使用基于条件的数据。 谢谢

© www.soinside.com 2019 - 2024. All rights reserved.