Tuesday, May 24, 2022

SSRS Font Weight expressions

Recently I was tasked to edit an old SSRS report, the report has multiple columns and I need to change the font weight to BOLD based on a specific value.

It's so simple but annoying that it needs to be done manually to all the columns that you need the expression to check. which was 25 columns in my case!

Steps:

  1. Right-click on the column and select "text Box Properties"
  2. Select "Font" from the left menu
  3. Next to BOLD click on the expression menu
  4. In the expression screen; write the expression based on your column and the condition.








=IIF(Fields!JB.Value > 0, "Bold","Normal")

So here I'm setting the Property "FontWeight" of the textbox to be "Bold" when the value is greater than 0, otherwise, you're setting it to "Normal".


hope that helps!

No comments:

Post a Comment