Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Text Colour and Background colour in a Pivot Chart

Hi all,

sounds like stupid question but i just can't get the text colour or background colour to work in this instance...

I have been able to in other instances but here it's not working for me...

I have qlikview pivot chart, in which I have a dimension (ISHCQTYAvailable) which has been pre-calculated in the load script, this gives the quantity available for a particular product.

I want the text to be red if it's in the negative, and green if it's in the positive and black, if it's just 0.

So in "Text Colour" under that dimension I have the following:

=IF(ISHCQTYAvailable > 0, Green(),

     IF(ISHCQTYAvailable < 0, Red(), Black()))

why isn't this working for me - any ideas?

Thanks in advance everybody!!

Fab

20 Replies
Anil_Babu_Samineni

Can you provide work file to test

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
vvira1316
Specialist II
Specialist II

You are trying to do Dimension background color or the expression background color?

Anonymous
Not applicable
Author

I would love to Anil,

But unfortunately this is part of a pretty large qlikview report, which is connected to our in house DB via ODBC...

I was hoping someone would be able to comment on my code...

thanks for your interest though...

Fab

prma7799
Master III
Master III

Try like this or Please share some sample app

Go to expression >>Text Color >>

if( ISHCQTYAvailable >=0    ,Green(),

if( ISHCQTYAvailable < 0  ,red(),

Black() ) )

Anonymous
Not applicable
Author

Hi Vijay,

My field is a dimension, not an expression...

It's been pre-calculated in the load script...

Thanks

prma7799
Master III
Master III

Please share some sample app

Anonymous
Not applicable
Author

Hi all,

thanks for your input...

I've just converted by pivot table into a straight table and the colours work no problems

Does anyone know how I can make text and background colours work (in dimensions) within a pivot table?

I don't understand why a feature like this would work in a straight chart but not a pivot chart???

prma7799
Master III
Master III

You can use it in dimension

Go to dimension >>Background Color >> ( Put those column no. which you want to apply on that basis)

e.g.

if( Column(2)>=0    ,Green(),

if( Column(2)< 0  ,red(),

Black() ) )

prma7799
Master III
Master III

Untitled.png