Sunday, February 26, 2012

Expand and collapse

My users want to be able to view a report in html and have the rows
expand and collapse on certain information. However they want to be
able to view the same report in PDF mode and be able to view all of the
drill down rows.
So my question is this is there a way to have a master expand and
collapse button so that the users would click it to make all of the
rows visible before exporting to PDF of do I need to create a second
report that does not collapse the rows and just have it linked to that
in PDF format?There is a way to have a "master expand all" button:
Assuming a table control is used:
1) Add a top group to your table and set expression to "=Nothing" and
check the include group header checkbox
2) Type in the top left textbox, we'll call it TxtAll, in the group
header for the new group "Expand All" (You could also leave it blank so
it doesn't look awkward on exported report)
3) Insert a new row under your details row in the table and duplicate
all of the fields exactly
4) For second detail tablerow, set Visibility-->Hidden to True and set
ToggleItem to txtAll
5) For all the textboxes in second detail row, set Visibility-->Hidden
to True and set ToggleItem to txtAll
6) For first detail tablerow, set Visibility-->Hidden to True and set
ToggleItem to txtAll
7) For all of the textboxes in the first detail row, set
Visibility-->Hidden to True and set ToggleItem to whatever textbox your
current report is using to toggle
Now the user can drill-down to any detail row or get all rows expanded
by clicking on the Expand All

No comments:

Post a Comment