January 12, 2015 at 8:45 am
I need help with an expression for Font color.
This is the current expression
=IIF(SUM(Fields!Hours.Value) > Fields!Max_Hours.Value, "Red", IIF(SUM(Fields!Hours.Value) < Fields!Max_Hours.Value, "Green","Orange"))
But sometimes the SUM(Fields!Hours.Value ) is NULL.
I need to tweak the expression so that if its NULL then it treats it as zero and gives the color as Green.
Currently its showing Orange.
January 12, 2015 at 9:04 am
Use ISNothing() - http://msdn.microsoft.com/en-us/library/dd283100.aspx
January 12, 2015 at 9:14 am
Yes , I am using Isnothing... But looks like at the wrong place 🙁
January 12, 2015 at 1:06 pm
What result do you get with this?
=IIF(SUM(Fields!Hours.Value) > Fields!Max_Hours.Value, "Red",
IIF((SUM(Fields!Hours.Value) < Fields!Max_Hours.Value OR IsNothing(SUM(Fields!Hours.Value))), "Green" ,
"Orange"))
Alternately you could try this (older syntax):
=IIF(SUM(Fields!Hours.Value) > Fields!Max_Hours.Value, "Red",
IIF((SUM(Fields!Hours.Value) < Fields!Max_Hours.Value OR SUM(Fields!Hours.Value) IS NOTHING), "Green" ,
"Orange"))
January 12, 2015 at 3:29 pm
Will try this for sure
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply