September 22, 2008 at 8:48 am
I want to add alternate row shading to make it easier to the user to read, but the syntax I tried below doesn't return any shading. Let me just say that I googled this and it was the syntax it said to use.
=iif(RowNumber(Nothing) Mod 2, "Sliver", "White")
Does anyone know how to make it work?
thx,
John
September 22, 2008 at 10:29 am
John,
First, make sure of your spelling. Hopefully you have "silver" and not "sliver" in your actual expression.
Second, make sure you have the expression in the background color property for the row and not for each individual textbox. SSRS just gets real flaky when you do that.
This is the syntax I use:
For colored background on odd number rows:
=IIF(RowNumber(nothing) mod 2=1,”Silver”,nothing)
For colored background on even number rows:
=IIF(RowNumber(nothing) mod 2=0,”Silver”,nothing)
If you're trying to do this for group headers you need this expression:
=iif(RunningValue(Fields!GroupField.Value ,CountDistinct,Nothing) Mod 2, "Silver", "Transparent")
HTH a little
[font="Comic Sans MS"]toolman[/font]
[font="Arial Narrow"]Numbers 6:24-26[/font]
September 22, 2008 at 1:31 pm
It's likely that your misspelling of 'Silver' is causing the report to show no formatting.
September 22, 2008 at 2:15 pm
yup, that was it. Beautiful. thx.
February 16, 2010 at 11:20 am
Thanks toolman
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply