ASP Report Viewer Changing Grouping during runtime

Using VS2008/c#/

1. Created a typed dataset as follows
    select last_name,first_name,location,dept,title from employee
2. Using Report Wizard created a group by Location Like
                    Last Name, First Name , Location, Dept, title

3. Assigned the rdlc to a report viewer control and it works fine.

My requirement to provide reports grouped  either by location, department or title.

I do not want to maintain 3 rdlc report for the above.
I wanted to use one  and change the grouping field at runtime  based on some condition like

Switch (groupby)
case: ‘LOCATION’
case:  ‘DEPT’
case: ‘TITLE’
default:  // By default it is grouped by location.

Any input is appreciated.

Who is Participating?
Rahul AgarwalTeam LeaderCommented:
yes it will work on both Winforms as well as Webforms, but the syntax may be changed in webforms to pass parameters.

for your reference please go through the link:
Rahul AgarwalTeam LeaderCommented:
please refer link:

it will help you to solve your problem
arvee2003Author Commented:
Thanks. I will take a look at it.

Hope it works in Local Processing Mode.

arvee2003Author Commented:
I am using VS 2008 and does this work in webforms

arvee2003Author Commented:
THanks. I did work out for me
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.