Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

If condition for colour change in table

Hello All,

I am trying to create an expression for colours which I am able to do for two colours but I need 3 colour change.

That is:

I need the colour to be green when my QS is >= 90RGB(0,128,0)

and red when it is below 90 RGB(255,0,0)

and white when it is below 85 RGB(255,255,255).

I am using the if statement for like

=If(QS>='90%', RGB(0,128,0),(255,0,0))

However, I cannot find a way to integrate the third condition and the third colour in my expression.

Thanks,

Hasvine

1 Solution

Accepted Solutions
maxgro
MVP
MVP

add another if

if(QS >= 0.9, RGB(0,128,0),                         // >= 90 green

if(QS < 0.85, RGB(255,255,255),                // < 85 white

RGB(255,0,0)                                                  // >= 85 <90 red

))

View solution in original post

1 Reply
maxgro
MVP
MVP

add another if

if(QS >= 0.9, RGB(0,128,0),                         // >= 90 green

if(QS < 0.85, RGB(255,255,255),                // < 85 white

RGB(255,0,0)                                                  // >= 85 <90 red

))