Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
fmazzarelli
Partner - Creator III
Partner - Creator III

background color expression

Hi Community,

may I create a formula using the label of a measure?

I would like create a backuground color expression:

if(Target > Percentuale, 'green', 'red')

Immagine.png

7 Replies
vinieme12
Champion III
Champion III

Have you tried yet?

IF(Target > 0.85,green(),red())

or you can use RGB() values

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
girirajsinh
Creator III
Creator III

yes

write that if condition in Backgroup Expression of the Field

e.g.

fmazzarelli
Partner - Creator III
Partner - Creator III
Author

Hi,

I explained bad. The color of the field is not on Target but on new field.

CUSTID      TARGET      newfield

3                     20%          background color expression

7                     15%          background color expression

On new field I would like to insert an expression to color the background of the cell

if CUSID > TARGET, red(), green())

fmazzarelli
Partner - Creator III
Partner - Creator III
Author

Hi,

Hi,

I explained bad. The color of the field is not on Target but on new field.

CUSTID      TARGET      newfield

3                     20%          background color expression

7                     15%          background color expression

On new field I would like to insert an expression to color the background of the cell

if CUSID > TARGET, red(), green())

fmazzarelli
Partner - Creator III
Partner - Creator III
Author

ops,

CUSTID AND TARGE

ARE CALCULATED FIELDS WITH NESTED IF STATEMENTS AND THAT'S WHY I WANT TO USE THE TAG

girirajsinh
Creator III
Creator III

That would work on new field as well in the same way

something like this

rahulpawarb
Specialist III
Specialist III

Hello Fabio,

I agree with Giriraj. You can define a new dimension in Table with Blank field value and assign a Background color expression as If(<Condition of your choice>, <Color code for pass>, <Color code for fail>) e.g. If(Time > 4, Green(), Yellow())

Hope this will help!

Thank you!

Rahul