I am using SSRS and have created a matrix has labor cost data for a business by Department then Pay Type (Regular, Overtime, Other and Temp labor) in row groups, for Months of the year (column groups). The column group cells are shaded for every alternate month starting with month 1 using switch;
=switch(Fields!Month.Value=1,"WhiteSmoke",Fields!Month.Value=2,"White",Fields!Month.Value=3,"WhiteSmoke",Fields!Month.Value=4,"White"...)
In the formula for the expression of the sum for the row group I have used the below to generate a 0 and not a blank when there is no data for the row group.
=IIf(IsNothing(Sum(Fields!Units.Value)),0,sum(Fields!Units.Value))
For every month there is Regular and Other labor cost, but not all months have Overtime or Temp Labor. The report does not generate a "placeholder" row for every type of labor if it does not exist. For example in a report for 12 months, month 1 and 3 might have no Temp labor (displayed as 0), but months 7 and 9 might have a Temp labor cost.
Problem : On the report display, cells in the columns that are supposed to be shaded in White Smoke have no shading if there is no data for that month. So for the example above cells in columns 1 and 3 for Temp labor are "No Color" while cells in months 7 and 9 are shaded in White Smoke. This makes the report look like it has "chicken pox"! Obviously there is no data for the row group for Fields!MonthValue so I tried to change the formula to the max value for the group of PayType
=switch(max(Fields!Month.Value,"PayType")=1,"WhiteSmoke"...)
but that generated a report error "Scope parameter not valid for an aggregate function".
Question: How do I shade all the cells in the alternate columns whether there is data or not?