13 Replies Latest reply: May 11, 2015 1:43 AM by Toni Kautto

# How to show  the different colors according to the various values?

Hi,All

I have a question like below

According to the column Sum(Sales) ,I want to make the value>12 show red and the value<0 show blue.how to written in the exepression?

Thankyou!

• ###### Re: How to show  the different colors according to the various values?

Hi,

You can do this in the visual cues tab.

Regards,

Greeshma

• ###### Re: How to show  the different colors according to the various values?

Helpful

• ###### Re: How to show  the different colors according to the various values?

Hi,

under your expression (clik on the + ) you can enter an expression which will define color

Try this expression :

If(Sum(Sales)>12,LightRed(),If(Sum(Sales)<0,LightBlue(),White()))

Instead of LightRed() or LightBlue(), you can also use the rgb function

Best Regards,

Sarah

• ###### Re: How to show  the different colors according to the various values?

Thankyou!answered

• ###### Re: How to show  the different colors according to the various values?

HI Li,

see the attached with examples of both methods.

HTH

Andy

• ###### Re: How to show  the different colors according to the various values?

Helpful

• ###### Re: How to show  the different colors according to the various values?

Use color wizard according to your value

Qlikview ColorMix Wizard by RFB 169 - YouTube

• ###### Re: How to show  the different colors according to the various values?

Helpful

• ###### Re: How to show  the different colors according to the various values?

Hi li,

To add colour logic in Qlik Sense try the following:

- Click the Edit button

- Select the table

- On the properties panel (right hand side), find your measure eg Sales

- Expand the measure properties

- Scroll down to the "Text colour expression"

- Enter a formula based on the desired logic eg If(Sum(Sales)>12, RGB(255,0,0), RGB(0,255,0))

This should then add the colour logic and if you want the logic to be the cell background rather than the text colour then put the above formula into the Background colour expression field.

Hope this helps.

Kind regards,

Rod

• ###### Re: How to show  the different colors according to the various values?

Thankyou!answered

• ###### Re: How to show  the different colors according to the various values?

Li Dan, it is great that you give feedback on helpful and correct answers!

Could you please do it with the Helpful and Correct options, so that the thread gets marked as resolved and your community friends get recognition for their contribution and effort?

For me the options look like in below image

• ###### Re: How to show  the different colors according to the various values?

Hi Toni,

I am in need of you, plz help me. i have 3 docs can any one plz help me creating 2 reports from that.can u plz help me to create reports , i have specs of the reports

• ###### Re: How to show  the different colors according to the various values?

Bayya Reddy, you need to create your own thread and detail what you are asking for help with. Hijacking an other thread like this is not the proper way.