SRS Report Grouping and Field Order based of parameter

B

BK Searcy

I have a report that displays basic time data, Client, Project,
Resource, Task and Actual Hours (Grouping on Client then Project then
Report) and I would like to expand the report to allow the user to
determine which order of the first three fields to group on. If I add
the parameters Group Field 1, Group Field 2 and Group Field 3 and have
the selection be one of the 3 fields (Editing to make sure each field
is selected and selected just once), how can I take the parms and
modify the order in which the report is displayed. As well as modify
whether a group is expanded or collapsed based off a user selection
(Modify the Visibility / Hidden attribute from a parameter)

I'm using Business Intelligence Studio in MS Visual Studio 2008 to
create and deploy my reports.

Thanks
BK
 
J

jack dahlgren

Sounds like you would have to write some functions to handle this.
I don't think there is a built-in way of dynamically changing the report
spec.

-Jack Dahlgren
 
J

Jonathan Sofer [MVP]

You can get fancy with the group by and expanding options based on parameter
selections like you said.

For example lets say you have a group by parameter called "GroupBy" with the
values 1,2 or 3 and the display values of Client, Project, or Resource
respectively.

In the layout you should be able to go to your group by definition and
instead of having the first level group on Client you can say something like
=IIF(Parameters!GroupBy.Value = 1, Fields!Client.Value,
IIF(Parameters!GroupBy.Value = 2, Fields!Project.Value,
Fields!Resource.Value)

You will have to then do similar type formulas for level 2 and level 3
groupings.

It can get complicated with the permutations because you have 3 levels of
groupings but it can be done. You can also have a parameter for each
grouping level and you can dynamically filter down the 3 option list for
each groupby parameter based on the users selection of the previous groupby
parameter. For example GroupBy2 will only show Client & Resource options if
GroupBy1 was selected to be Project, etc.

You can do the same with another parameter to control the expanded by
default or not. The formula needs to reference the parameter and the
results are either true or false.

I know that VS2008 has a different look and feel than VS2005 so I'm not 100%
on how to navigate to the group on and the visibility tabs but I'm sure they
are there somewhere.

Jonathan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top