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

BAR CHART PLOT AREA COLOUR BASED ON EXPRESSION

Hi, does anyone know if its possible to change the plot area background colour based on an expression?

Basically i want the expression to do the following -

IF Y-AXIS > 0 THEN LIGHTGREEN PLOT AREA COLOUR

IF Y-AXIS < 0 THEN LIGHTRED PLOT AREA COLOUR

I was thinking of the following calulated expression:

=IF( YAXIS >0, LIGHTGREEN(), LIGHTRED())

also see my screenshots below

--------

error loading image

error loading image

17 Replies
Not applicable
Author

Hello,

I have exactly the same question, does anyone knows how to do it?

Thanks in advance!!

Anonymous
Not applicable
Author

Hi

I hope I have understood your requirement correctly:

On your Chart Properties

  • Go the Presentation tab
  • Select  Color [bottom left]
  • Click color box under Background
  • For Base Color select Calculated and enter you required expression

Best Regards,     Bill

Clever_Anjos
Employee
Employee

Goes to your Expression tab, click on '+' near your expression and put your expression

IF( column(1) >0, LIGHTGREEN(), LIGHTRED())

Anonymous
Not applicable
Author

It works for bars but not for the background plot area.  I think that the plot area color, even if calculated, is one per chart.

Regards,

Michael

Not applicable
Author

I think Michael is right... It seems we cannot create a multiple color plot area background based on axis values...

Clever_Anjos
Employee
Employee

Sorry, misunderstood the issue

quiquehm
Contributor III
Contributor III

This is really a pitty. I have an scenario where I am using kind of a Gantt chart in qlikview with many project milestones spread over time and I set a reference line on the chart ( today() ) . It would be really helpful for me to be able to setup a calculated color for the plot area based on the today() ref line...so all space before today() goes grey ( all past activities ) , then a color band between today() and today()+10 would go yellow to alert me of all activities milestones coming due in the next 10 days.

Could someone confirm whether this is definitively not possible?

Thanks

Plot_Area_Calc_Color.jpg

Not applicable
Author

Any chance someone found a fix for this? I am interested in having red/green/yellow background areas of a chart.

TKendrick20
Partner - Specialist
Partner - Specialist

I have this exact same problem. Have you found a solution?