SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 Alternate line formatting on matrix style reports
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

JAG7777777
Starting Member

United Kingdom
25 Posts

Posted - 12/05/2012 :  08:14:26  Show Profile  Reply with Quote
We have a standard formatting on table style reports which alternates the background colour of each row between grey and white using an expression. This works fine when it is a standard table tablix.
However, when we employ the same expression on matrix tablixes with grouped rows and columns it looks a mess - presumably due to the groups being present.

Has anyone worked out a way of formatting a matrix report that has groups on both the columns and rows - but still prints out with an alternative background colour (i.e. similar to the old white and green computer paper)?

Many thanks,

jag7777777

JAG7777777

visakh16
Very Important crosS Applying yaK Herder

India
52325 Posts

Posted - 12/06/2012 :  02:14:15  Show Profile  Reply with Quote
can you show a screenshot of how you want formatting to be done in matrix groups?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

JAG7777777
Starting Member

United Kingdom
25 Posts

Posted - 12/06/2012 :  04:02:04  Show Profile  Reply with Quote
Hi visakh16,

Thanks for your reply.

Managed to resolve this last night. I used the following expression in the background colour:

=iif(RunningValue(Cstr(Fields![RowGroupNameHere].Value),CountDistinct,"DatasetName") Mod 2,"LightGrey", "White")

This exploits the CountDistinct across the entire matrix's rows to essentially provide a row counter at each row group on the matrix - which can then be used with the Mod 2 to return either a 1 or a 0. Seems to work really well so thought I'd share for anyone else having the same problem :-)


JAG7777777
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.06 seconds. Powered By: Snitz Forums 2000