Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

fix colours

Afternoon

I have a number of bar charts which display values for the regions in our company. How do I fix these to be a certain colour

i.e. North = Blue, Scotland = Red etc. I know what the rgb values. I've been trying to put an expression in the colors tab but it doesnt seem to be working

Can someone advise

Thanks

1 Solution

Accepted Solutions
MayilVahanan

HI

In expression tab, click the '+' sign and try like this

=Pick(Match(only(FieldName),'North','Scotland'),blue(),red())

Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

5 Replies
Not applicable
Author

Under Expressions > Background Color, write your expression.

Capture.JPG

Not applicable
Author

For example:

If(Region = 'North', RGB(0,0,255),

if(Region = 'Scotland', RGB(255,0,0))

MayilVahanan

HI

In expression tab, click the '+' sign and try like this

=Pick(Match(only(FieldName),'North','Scotland'),blue(),red())

Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
swuehl
MVP
MVP

Check Henric's recent blog post on how to use consistent colors across multiple charts:

http://community.qlik.com/blogs/qlikviewdesignblog/2012/12/04/colors-in-charts

Not applicable
Author

Thank you all for a prompt response - all sorted now