ASP Report Viewer Changing Grouping during runtime

Using VS2008/c#/odp.net

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
        Location
                    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.

Suresh
arvee2003Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Rahul AgarwalConnect With a Mentor Team 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:

http://www.codeguru.com/cpp/cpp/cpp_mfc/templates/article.php/c12721__2/Dynamic-Data-Grouping-Using-MS-Reporting-Services.htm
0
 
Rahul AgarwalTeam LeaderCommented:
please refer link:

http://www.codeproject.com/KB/reporting-services/DataGrouping.aspx

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

Hope it works in Local Processing Mode.

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

Suresh
0
 
arvee2003Author Commented:
THanks. I did work out for me
0
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.