How to Hide /Show report columns

  • Hi All,

    How can i hide/show report column in an ssrs report? I have a report which is used by differnt users and some are not intrested in all the columns of the report. How can i hide columns only for them. I dont want to create two separate reports for this.

    Please let me know if its possible?

    Many thanks.

  • Hi,

    This should be possible.

    There is a globals field (=User!UserID) which returns the id for the user who is running the report.

    I would first of all place the user id field in a cell somehere in your report to see the value that is returned.

    Then select the column or fields you to want to conditionally suppress then look in the properties window (if you can't see it press F4 or in the menus click on view and properties window) under visiblity click on the drop down next to hidden and select expression then you will need to type in something like =iif(=User!UserID="john",False,true).

    Let me know how you get on 😉

  • Hi,

    Thanks for the response, one more question how can I get that global Field do i have to create it ?

  • No it is a global field and is already there, in the expression window click on globals in the menu and you will see it there.

  • Thanks once again, my issue now is that I had to create one reporting user and stored that users credentials on the data source. So no matter who is running the report it is those credentials which are used.

    Not sure what to do now.

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply