Click here to Skip to main content
15,886,840 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am very inexperienced with SSRS and have no VB experience.

My report has detail rows which of employee ours grouped by department with subtotals at the department level. The subtotal lines have the word 'Total' in a textbox on that line.

When the report initially displays, the department name and department head names are shown, with hour totals for the department. I would like to have alternating background colors for these totals.

When you expand the (+) next to the department head name, the details of each employee in the department are displayed. These detail lines can be all the same background color, or the same background color within the group.

I have tried a few different approaches, but nothing seems to be working.

What I have tried:

I have tried the setting up a variable as described here:http://www.mike250.com/ssrs-alternate-row-colors-of-a-group/
but it didn't affect the report at all. (It is possible that I didn't put the variable in the right place, the report previews without error).
The closest I have come to getting this the way I want was to simply right clicking on the textbox with the 'Total' text in it and setting the Fill as follows: =IIF(RowNumber(Nothing) mod 2, "gray", "green") The results of this were to have The 1st, 3rd, 4th, 5th 7th and 8th Total lines gray and the 2nd, 6th, and 9th rows green. There are variable numbers of detail lines within the groups. If/When I get this right for this Total textbox, I can then use the same approach for the other columns in that row.

I have played with IIF InStr(Gields!textbox7.Value,"Total"..., RunningValue(Fields!DeptHead,UniqueName...), reportItems!textbox7.Value...

It is all starting to look like alphabet soup!
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900