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

Color String in Expression Editor

Hello experts!

I am trying to color a string like this chr(9733)&chr(9733)&chr(9733)&chr(9733)&chr(9733) in the expression editor!

It is the dimension of a bar chart, how can i do it? i would have the stars (the result of the chr() function) coloured!

The exact code is:

if([ ]='Excellent', chr(9733)&chr(9733)&chr(9733)&chr(9733)&chr(9733), 

if([ ]='Very Good', chr(9733)&chr(9733)&chr(9733)&chr(9733)&chr(9734), 

if([ ]='Average', chr(9733)&chr(9733)&chr(9733)&chr(9734)&chr(9734),

if([ ]='Poor', chr(9733)&chr(9733)&chr(9734)&chr(9734)&chr(9734),

if([ ]='Terrible', chr(9733)&chr(9734)&chr(9734)&chr(9734)&chr(9734))))))

Thankyou!

3 Replies
Gysbert_Wassenaar

The entire string can have only one color. It's not possible to give some stars one color and other stars in the same string another color. You can change the color by clicking on the + character in front of the dimension on the Dimensions tab, then click on Text Color and enter an expression in the Definition input box that calculates a color. Examples are color(1), lightred(), rgb(0,255,255)


talk is cheap, supply exceeds demand
Not applicable
Author

Thank you Gysbert for your fast reply!

I actually cannot find the path you told me, i am using a Qlik Sense Desktop version! Where do I have to go?

(the dimension refers to a bar chart)

Thanks!!

Gysbert_Wassenaar

Oops. My mistake. In Qlik Sense you can change the color of the bars, but not of the dimension labels. If you need that kind of functionality you'll have to find or create an extension or widget that offers that option.


talk is cheap, supply exceeds demand