在 RDLC 报告中更新数据源 [英] Update datasouce in RDLC report

查看:50
本文介绍了在 RDLC 报告中更新数据源的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 SQL 视图将数据传递给 RDLC 报告.现在,如果我在 SQL 视图中添加一列,如何在 RDLC 报告中获取这个新添加的列.

I am using SQL views to pass data to RDLC report. Now If I add a column to SQL view, How can I get this newly added column in RDLC report.

现在,我必须每次都删除 RDLC 数据集并创建新的数据集,这根本不可行.希望有人有更好的方法来做到这一点.

For now, I have to delete RDLC dataset and create new one every time which is not feasible at all. Hope someone have better way of doing this.

推荐答案

您可以在任何 XML 编辑器中打开您的报表,找到您的数据集并在字段"部分添加更多列(所需类型).例如:

You can open your report in any XML editor, locate your dataset and add more columns (of desired type) in Fields section. For example:

    <Field Name="NewColumnName">
      <DataField>NewColumnName</DataField>
      <rd:TypeName>System.String</rd:TypeName>
    </Field>

这篇关于在 RDLC 报告中更新数据源的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆