开发者

Make hidden table column take no space in SSRS 2008 R2

Has anyone figured out a good way to make a hidden table/matrix column take no horizontal space?

I could use some crazy conditionals to dynamically determine the contents of the columns (effectively sliding them leftward as far as possible), but that is nasty, plus doesn't allow for varying column widths in the columns to the right of the one I want to hide.

The idea is that when a parameter is set to "Any" then the column with the corresponding value should display. But when the parameter is set to an explicit single value the report doesn't need to contain that column any more (it will be separately listed as a condition at the top of the report).

This lets me use the same report in different situations, some requiring hiding unnecessary columns.

P.S. I think Microsoft should add expressions for o开发者_JAVA技巧bject sizes, and I think they should add CanShrinkHorizontally to the CanShrink(Vertically) that already exists...


I think you are looking at the Hidden property of the column. Something that is hidden will still take up space. What you want to change is the Visibility of the column. Right click on the column header and click Column Visibility and set it there.


It looks like you can hide groups, and groups can be rows or columns.

Click the down-arrow next to "Column Groups" at the bottom of the Design pane, and turn on Advanced Mode. Modify the Hidden property of the Static group representing the desired column. Poof! You've made the entire column take up no space.


I struggled with this and came up with a workaround/solution.

In my scenario it was critical to have the RowGroups EffectiveDate, Description AND TransactionID. I wanted to hide the TransactionID column, because it was part of the grouping I couldn't set the Columns Visibility.

Before

Make hidden table column take no space in SSRS 2008 R2

After

So what I did was Merge Cells for the Description/TransactionID Header (and called it Transaction Type) and also for the first row of the tablix "Opening Balance".

Set the TransactionID textbox Hidden: True

The trick was to make the [DESCRIPTION] Right BorderStyle: None

Make hidden table column take no space in SSRS 2008 R2

Then set the Cell under [TRANSACTIONID] Top BorderStyle: Solid and Top BorderWidth 0.5

Make hidden table column take no space in SSRS 2008 R2

Alternatively make the fore color of the column you want to hide white and set border styles appropriately.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜