locked
show/hide report columns RRS feed

  • Question

  • Hello,

    I'm currently investigating whether SQL Reporting Services might be the right solution to some reporting requirements I have been given (web reports).

    There is a requirement that some of the columns are hidden to begin with and can be shown by clicking on the header of one of the other columns. E.g. There is a list of clients and a "Total Revenue" column, clicking on the "Total Revenue" column header would show an additional 5 or so columns which show a breakdown of different figures that make up the total revenue.

    So my question is this: Is it possible to show/hide columns by clicking on the headers of other columns in the report?

    Thanks,

    Lachlan

    Tuesday, August 29, 2006 3:18 PM

Answers

  • Changing the visibility of the cells didn't exactly work for me. Although by changing the visibility of the cells in the column does hide them, it leaves a big white gap in the middle of my table! In other words, the other columns stay where they are instead of moving over to fill up the space.

    To have the columns automatically fill in the place where the hidden column is, toggle the visibility as follows. Right clicking on the column itself (they grey bar at the top of the column) and click 'properties'. In the properties pane expand 'visibility' and change 'Hidden' to 'False'. Now put the name of your other column as the 'ToggleItem' value and thats it!

    Lachlan

    Friday, September 8, 2006 2:52 PM

All replies

  •  

    For each of the 5 columns , right click on the cell holding the value to be displayed and click on properties.

    Click on Advanced button on the lower left

    Click on the visibility tab and click the check box "Visibility toggled by another report item"

    Select the column header (which is just another cell on the layout page)

    This should be all you need to toggle the visibility

     

    Thanks

    Umesh

     

    Tuesday, August 29, 2006 3:51 PM
  • Changing the visibility of the cells didn't exactly work for me. Although by changing the visibility of the cells in the column does hide them, it leaves a big white gap in the middle of my table! In other words, the other columns stay where they are instead of moving over to fill up the space.

    To have the columns automatically fill in the place where the hidden column is, toggle the visibility as follows. Right clicking on the column itself (they grey bar at the top of the column) and click 'properties'. In the properties pane expand 'visibility' and change 'Hidden' to 'False'. Now put the name of your other column as the 'ToggleItem' value and thats it!

    Lachlan

    Friday, September 8, 2006 2:52 PM
  • try use the 'visibility' of the column and not the cell.
    Monday, January 1, 2007 12:22 PM
  • I needed to conditionally change the visibility of a column based on the value of a parameter.  Searching the threads on this topic, the message I kept reading was it is not possible in SSRS.  With some creative thinking, I found it to be quite easy.  Here is my solution...

    In the Hidden property (under Appearance...Visibility), enter an expression such as this...

    =iif(Parameters!p_test.Value="XYZ",True,False)


    Naturally, "p_test" should be replaced with your parameter and "XYZ" should be replaced with the appropriate value for your parameter.

    Within the threads, I heard mention of using the Hidden property but nobody ever mentioned using an expression.  I had sort of assumed one could only have True or False for the value but the expression worked fine.
    Tuesday, December 18, 2007 9:54 PM
  • I should have clarified that this is the Hidden property for the column -- not a specific cell(s).
    Wednesday, December 19, 2007 4:26 PM