Forum Discussion

PowerrrBrrr's avatar
PowerrrBrrr
Helper III
4 years ago
Solved

Easy Conditional Text based on column values

Hi I have below visuals which are card visuals whose background has been formatted based on values. Like if value is 0 then red else green. I would also like to show Active and Inactive text for gree...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi  PowerrrBrrr ,

    Here are the steps you can follow:

    1. Create measure.

    color =
    IF(
        MAX('Table'[Value])=0,"red","green"
    )
    status =
    IF(
        MAX('Table'[Value])=0,"Inactive","Running")

    2. Select Format – Conditional formatting – Machines – Background color.

    3. Enter the Background color interface.

    Format by – Field value

    Based on field – [color]

    4. Result:

    Does this match your expected result?

     

    Best Regards,

    Liu Yang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly