Expand Collapse all columns in SSRS reports in one single option
To expand and collapse all columns in your report by selecting a single option: here by selecting a value to a parameter 1. create one Report parameter parametername: showall which has non-queried values as follows: label values ~~~ ~~~~~ Yes Expanded No Collapsed Initial value is: Non-Queried : Expanded 2.set visibility property of the row to: =iif(Parameters!ShowAll.Label ="No",true,false) or =iif(Parameters!ShowAll.Value = "Collapsed", True, False) set toggleItem to atextbox (eg: textbox1) 3. set (textbox1)InitialToggleItem property =iif(Parameters!ShowAll.Label ="Yes",true,false) or =iif(Parameters!ShowAll.Value ="Expanded",true,false) RESULT: ---------------------------- ShowAll? YES Animals Name -Dog xxxxxxxx xxxxxxxx -Cat xxxxxxxxx xxxxxxxxx ---------------------------- ShowAll? No Animals Name +Dog +Cat <Expression...> Rocks!!!! now u can make all the report data to expand and collapse in single option...visit often: http://coooollll-ssrs.blogspot.com
October 17th, 2008 10:17am

Thank you for sharing this helpfultip and the nice writeup- I'm sure it might help other readers on this forum. -- Robert
Free Windows Admin Tool Kit Click here and download it now
October 20th, 2008 12:35am

Hello Robert, Thanks for your appreciation.. Hopefully i would share all after such a nice appreciation..
October 20th, 2008 7:47am

Hi, Thankk you for sharing your knowledge. This is great... I'm struglling to use a textbox insted of a parameter in the expression. Great Stuff
Free Windows Admin Tool Kit Click here and download it now
November 16th, 2008 12:23pm

Hi Cool,Thanks for this post.I am trying to expand all the rows, some how it expand only the first row.Is there anything i am missing.Need help ASP.Thanks in advance.Masi
February 6th, 2009 3:46am

Hi Masi,sorry for the late reply.. i was little busy with some issues while configuring Reportserver in IIS 7.0In the above eg. i have used only one textbox like belowAnimals Name +Dog +Catif u r using like this: consider for eg.Animals Name Breed -Dog -jimmy dalmations bulldog -Cat -roseset (all of the appropriate text boxes's)InitialToggleItem property to (as in step:3) =iif(Parameters!ShowAll.Label ="Yes",true,false) or =iif(Parameters!ShowAll.Value ="Expanded",true,false) let me know whether i got ur question right and this solves ur problem.. Hope i have stated the eg. more clear in my bloghttp://coooollll-ssrs.blogspot.com/ coooollll
Free Windows Admin Tool Kit Click here and download it now
February 20th, 2009 1:30pm

Hi ismail,thanks for ur comments..Expressions rocks!..... :-) coooollll
February 20th, 2009 1:32pm

But does these steps really works with SSRS 2008 ? I have been trying to do it for a day... but the initial toggle status are always collapsed, no matter what I set the "Initial Toggle State" to.... for the table details row group...
Free Windows Admin Tool Kit Click here and download it now
September 22nd, 2009 2:57am

Hi All,The steps does not seems to work with SSRS 2008, any other ideas..
December 31st, 2009 9:39am

Hi Lakshmipriya, Im sure this ll work in SSRS 2005.. And I haven't yet tried it in SSRS 2008.. I ll Let you know how to do this in SSRS 2008...coooollll
Free Windows Admin Tool Kit Click here and download it now
December 31st, 2009 10:01am

Hi coooollll,Have you tried this yet in SSRS 2008. I'm having difficulty.Thanks
January 3rd, 2010 9:04am

Hi All,I was able to get this done in SSRS 2008.Please find the below link , which tell us how to get it done..http://social.msdn.microsoft.com/Forums/en-US/sqlreportingservices/thread/a6a26646-5439-4b31-803d-baf3e9fe0bd0go through the Books sample projects ....Expand Collapse All.rdlhttp://www.wrox.com/WileyCDA/WroxTitle/Professional-Microsoft-SQL-Server-2008-Reporting-Services.productCd-0470242019,descCd-DOWNLOAD.html. RegardsLakshmi Priya
Free Windows Admin Tool Kit Click here and download it now
January 22nd, 2010 10:43am

Great tip - thanks for sharing! -Simon D
April 8th, 2010 7:04pm

For SSRS 2008: I just used a boolean parameter called ExpandAll defaulted to false. Your textbox(eg textbox1) that controls the toggle must have the InitialToggleState must be set equal to Parameters!ExpandAll.Value. This sets the Plus/Minus directly mapped to the false/true respectively. The way to do this in SSRS 2008 (and VS 2008) is to click on textbox1, then in the Properties tab set it there. SSRS 2008 stripped out a lot of the properties out of the Properties Popup Window, but most are still there, just in the Properties Tab. The row/group visibility must have it toggle based on textbox1(or whatever the name of your textbox is). Then your row/group that toggles based on textbox1 must have their visibility set to "=Not Parameters!ExpandAll.Value" This sets the Hidden to true if ExpandAll is false or vice versa.
Free Windows Admin Tool Kit Click here and download it now
July 7th, 2010 7:25pm

Exactly. I had the same issue. When I click on + it used to collapse instead of expanding. so I had to set the same expression in the properties window for that textbox and also I had to use the expression in the grouping pane.
July 7th, 2010 8:08pm

That does rock. It rocks very hard indeed! Thankyou!
Free Windows Admin Tool Kit Click here and download it now
February 15th, 2011 8:14am

This works great except for the collapse function does not display the detail group data when expanded or the + is clicked Also is there a way to toggle this without the user having to change the parameter selection and view report again maybe a toggle button inside the report? Thanks
April 4th, 2011 3:21pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics