RDLC Column visibility expression throws error: Native compiler return value: is not accessible in this context because it is 'Friend'

RDLC Column visibility expression throws error: Native compiler return value: is not accessible in this context because it is 'Friend'

我想在 运行 时间在我的 RDLC 报告中显示或隐藏 table 的某些列。我正在发送要在单独的数据源(仅包含列名称)中显示的列列表。

我在列可见性表达式中添加了以下公式(目的是仅当数据集包含带有 STATUS 条目的记录时才显示 STATUS 列)。

=iif(instr(Fields!myData.Value,"Status") > 0, false, true)

当我 运行 报告时,我收到以下错误消息。但是,如果我将此表达式放在 table 的任何列中以查看结果,则它可以正常工作。

An error occurred during local report processing.;The definition of the report '......\netcoreapp3.1\Reports/FlightScheduleArrival.rdlc' is invalid.\r\nAn unexpected error occurred while compiling expressions. Native compiler return value: ‘[BC30390] 'AspNetCore.ReportingServices.RdlExpressions.ExpressionHostObjectModel.DataRegionExprHost(Of TMemberType, TCellType).m_memberTreeHostsRemotable' is not accessible in this context because it is 'Friend'.’."

听起来像库 'AspNetCore.ReportingServices' 尝试访问“AspNetCore.ReportingServices.RdlExpressions.ExpressionHostObjectModel.DataRegionExprHost”中的 m_memberTreeHostsRemotable。

需要在 'DataRegionExprHost' 中添加一个 attribute 以允许访问,创建者可能忘记了。

这是 .NET Core 的第三方 RDLC 报告库。 'ReportingServices' 的源代码未发布,因此我们无法自行修复。

因为 'ReportingServices' 是由同一个开发者制作的。您需要在 github 页面中编写错误报告,希望得到修复。