Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Leverage your QlikView investment to modernize BI – see how! Join Group
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator II
Creator II

Colour in an Expression

Hi,

I have an expression in my QV app, and this might sound a bit simple, but I want the result in my pivot table to be red, if less than 0, and black if not.

I know about the '+' sign next to the expression name, but have never really used it.

If I wanted to do the above, would I have to repeat my expression in the 'Text Colour' field, or can I just add in <0, Red(), black().

This if my formula in my expression field:

if(Company=29,(sum([Line Debt])/100*$(Medical)),

if(Company='100D',(sum([Line Debt])/100*$(Pest)),

if(Company='100K',(sum([Line Debt])/100*$(Wash)),

if(Company='100F',(sum([Line Debt])/100*$(Hygiene)),

if(Company='100Z',(sum([Line Debt])/100*$(Ambius)),0)))))

Thanks

Di

1 Solution

Accepted Solutions
Highlighted
Not applicable

Re: Colour in an Expression

Hi DiNicholls,

Here you must have to write expression in the background color which appears when you click on the + sign.

Expression to be written is if(Line<0,Red(),Black())   where Line is the Label of you expression.

Please fine the screen shot for the same.Line Debt.png

View solution in original post

6 Replies
Highlighted

Re: Colour in an Expression

Just adding in <0, Red(), black() should suffice.

Give it a go and tell us whether or not you have success.

Highlighted
Partner
Partner

Re: Colour in an Expression

Use visual cue tab and put a color if lower than 0

Highlighted
Not applicable

Re: Colour in an Expression

Hi DiNicholls,

Here you must have to write expression in the background color which appears when you click on the + sign.

Expression to be written is if(Line<0,Red(),Black())   where Line is the Label of you expression.

Please fine the screen shot for the same.Line Debt.png

View solution in original post

Highlighted
Specialist
Specialist

Re: Colour in an Expression

Hi Diane

Visual Cues in Properties work best for simple highlighting. I think this will work OK for you. Otherwise the '+' gives more variety (eg. cell background) but sometimes you need to hunt around for documentation on how best to use the features (eg. bold font). This community is a good source.

Highlighted
Creator II
Creator II

Re: Colour in an Expression

Thank you all!

Didn't realise it was that simple!

Highlighted
Not applicable

Re: Colour in an Expression

Its ok. The more we post, More we learn.