ddschreck01
asked on
change crosstab group option from monthly to quarterly during runtime
How can I change a cross tab column (a date) from grouping monthly to quarterly at runtime?
I don't think you can do this. You can create 2 subreports with crosstabs - 1 grouped by date and another one by month and hide the wrong subreport based on a parameter
ASKER
Thanks. I was afraid that was the case. I like your suppress idea. Thanks.
Why the need for subreports?
You can use 2 cross tabs on the report and suppress one of them
Another idea
Add a parameter to select the monthly or quarterly
Add a formula to the report
Duration
Use the formula duration to cntrol the crosstab
mlmcc
You can use 2 cross tabs on the report and suppress one of them
Another idea
Add a parameter to select the monthly or quarterly
Add a formula to the report
Duration
Local StringVar x;
If {?Duration} = "Quarter" then
(
If Month({tblHoursWorked2012.Started}) <= 3 then
x := "1"
Else If Month({tblHoursWorked2012.Started}) <= 6 then
x := "2"
Else If Month({tblHoursWorked2012.Started}) <= 9 then
x := "3"
Else If Month({tblHoursWorked2012.Started}) <= 12 then
x := "4";
)
Else
x := CStr({tblHoursWorked2012.Started},"MM");
CStr({tblHoursWorked2012.Started},"yyyy") & "-" & x
Use the formula duration to cntrol the crosstab
mlmcc
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.