简体   繁体   English

SSRS-通过使用tablix通过子报表显示标题?

[英]SSRS - Display header through subreports by using tablix?

I have a main report containing 5 subreports. 我有一个包含5个子报表的主报表。 My ultimate goal is to have a header with an image in it to only show within 2 of the subreports. 我的最终目标是使标题中包含图像,以便仅在两个子报表中显示。 I'm trying to achieve this by using a tablix and putting all of my subreports into the tablix on the main report, and putting the image into the header of the tablix and using a hide/show query based on subreport name. 我正在尝试通过使用tablix并将所有子报表放入主报表的tablix中,然后将图像放入tablix的标题中,并使用基于子报表名称的隐藏/显示查询来实现此目的。

The problem is that when I put the subreports into the tablix and upload it to CRM it won't display at all. 问题是,当我将子报表放入tablix并将其上传到CRM时,它根本不会显示。 If I remove the tablix the subreports will run and display perfectly. 如果删除tablix,则子报表将运行并完美显示。 Can anyone tell me what I'm missing here or an alternative if there is an easier way to achieve what I want? 谁能告诉我我在这里缺少的内容,或者有一种更简便的方法来实现我想要的功能吗?

Thanks. 谢谢。

Tablix with a row above the detail group so it shows a header for each line is a good idea, but creating the header within the actual report and adding a new parameter which tells the report whether to show the header or not is a good idea as well. Tablix在明细组上方有一行,以便在每行显示一个标题是一个好主意,但是在实际报告中创建标题并添加一个新参数可以告诉报告是否显示标题是一个好主意,因为好。 If you go for the second, you can set a default value to show or hide the header depending on your needs. 如果您第二次尝试,则可以根据需要设置默认值以显示或隐藏标题。 I use to create a param called "Execution Mode" with some fixed values as "*Interactive","*Excel", "*SubreportA", ... so I can control it's behavior in all situations, for instance, when you export to excel, you what to hide some elements in the report so it doesn't create those funny merged cells which are anyone's nightmare when trying to filter or order a list. 我用一个固定的值创建一个名为“执行模式”的参数,例如“ * Interactive”,“ * Excel”,“ * SubreportA”等,这样我就可以控制它在所有情况下的行为,例如,在导出时精益求精,您该隐藏报表中的某些元素,以便它不会创建那些有趣的合并单元格,这些单元格在尝试筛选或排序列表时是任何人的噩梦。

Hope this helps. 希望这可以帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM