Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Problem with bar chart color

I experts,

I want to color my bar in function of the value of my data "Delta" but when I write my code in the calculated base color 1 (of 1-6), it doens't work.

My code : if(Delta < 100,red())

The result is blue when my value = 56...

Could you help me please ?

Best regards,

Pierre.

3 Replies
Anonymous
Not applicable
Author

Hi Pierre,
Not enough enformation, so I'm just trying to guess, hope it at least will give you directions.
Apparently something is wrong with "Delta" - it is not what you expect here.  What is the bar expression itslef?  If it is, for example, sum(Delta), the color expression should be if(sum(Delta) < 100,red()).

Regards,
Michael

neetu_singh
Partner - Creator III
Partner - Creator III

Hi,

In Expression use sum(Delta) and then click on "+" at Expression tab and on Background Color write this expression:

if(Sum(Delta)<'100',rgb(255,0,0)). It will work.as mention belowa.bmp

Please find attached sheet.

Regards

Neetu SIngh

Not applicable
Author

Neetu,

Thanks a lot for the information. Its really helpful.

Regards

Siva Rama