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

Pivot Table Cell Color

Hi,

I have below data in pivot table,

Pivot.JPG

I want to change background color of cell based on condition if previous year sales is less than current then cell background is green else red.

Thanks,

Villyee

2 Replies
petter
Partner - Champion III
Partner - Champion III

  • Go to the properties dialog of the Pivot Chart.
  • Select the "Expressions" tab.
  • Click the + icon to the left of the Sum(Sales) expression.
  • Then select "Background Color" and in the "Definition" add the expression
    If( Before(Sum(Sales)) < Sum(Sales) OR ColumnNo()=1 , Green(100),Red(100))
  • Click OK.

2018-07-30 08_35_35-Edit Expression.png

mtucholski
Creator
Creator

if(before(sum(Sale))<sum(Sale),lightgreen(),lightred())