1

How do change part of the string's color in SSRS based on conditional logic.

This is what the expression currently looks like:

=" Total Amount Due: " & FormatCurrency(ReportItems!GrandTotal.Value)

What I want to do is something like this iif(ReportItems!GrandTotal.Value >= 0, "red", "black") but we only want to change the color of the GrandTotal field rather then the complete string.

I understand how to change color based on conditional logic, but I can't figure out how to change color based on conditional logic only for part of the expression

YelizavetaYR
  • 1,611
  • 6
  • 21
  • 37

1 Answers1

1

You can try to put the static text outside of your placeholder expression, but in the same textbox. You can then remove the "Total Amount Due" from your expression and you can set your conditional logic to the entire expression, which will only have the value.

enter image description here

papermoon88
  • 456
  • 2
  • 8
  • it doesn't seem to allow me to create a placeholder in the text box – YelizavetaYR Oct 14 '21 at 17:28
  • When I mentioned placeholder, I'm also referring to your expression. They are essentially the same thing. You don't need to create a new one, you can just use the one you have. I think you sometimes might need to double click the textbox to get the cursor to show up. – papermoon88 Oct 14 '21 at 17:35