SQL Scrapbook

Short and simple SQL Server posts

Posts Tagged ‘Alternate Row Color SSRS

Different background color for alternate rows

leave a comment »

It’s a very common request to alternate the background color of rows in SQL Server Reporting Services. There is a simple way to this and we will see how.

In the properties window of the detail row(of the data region), find background color and choose expression. In the edit expression window, paste this expression.

=IIF( ROWNUMBER (NOTHING) MOD 2, “Silver“,”Grey“)

Click Ok and you are all set.

Advertisements

Written by sqlscrapbook

July 24, 2010 at 1:32 pm

Posted in SSRS

Tagged with