Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Colour List Box Items depending condition

Hi,

I need to use a listbox as a navigation pane and I need to be able to colour these items depending on a condition - eg, Red Background, Amber Background or Green Background.  (so the user can 'drill down' an item depending on its score)

Is this possible ?? If not is threre a more suitable solution?

Im already using the expression to colour a text object :

=if(vPrevMonthScore<vCurrMonthScore,rgb(83,230,62), //Green

if(vPrevMonthScore>vCurrMonthScore,rgb(255,47,47), //Red

    rgb(233,165,39))) //Amber

Ideally I would like to use this expression to 'colourise' the listbox

Any help and suggestions greatly appreciated,

Many thanks

1 Solution

Accepted Solutions
Not applicable
Author

Same can be applied in dimmension as well, try the same in dimmension

Regards

Himanshu

Skype- himanshu_sethi

View solution in original post

5 Replies
Gysbert_Wassenaar

As far as I know that's not possible with listboxes. You could try if an extension object like the one mention here offers more options. Or you can try to create a fake listbox using a straight table. The disadvantage of the straight table is that it's not possible to select multiple items individually (ctrl+click) like in the listbox.


talk is cheap, supply exceeds demand
Not applicable
Author

HI,

Thanks for your reply.  I've gone for using a straight table chart and am trying to test the each of the dimensions against the expression.

With regard to this, are you able to help further? Do you have any advice on how to use the expression  :

=if(vPrevMonthScore<vCurrMonthScore,rgb(83,230,62), //Green

if(vPrevMonthScore>vCurrMonthScore,rgb(255,47,47), //Red

    rgb(233,165,39))) //Amber

to test each dimension in the straight table chart? eg:

qv_rated_list.png

Im guessing some Set Anaylsis is required - but unfortunately Im very new to QV. 

Many thanks again for your help.

Not applicable
Author

Go to expression Tab, Expand the Expression click on backround and put your desired condition over there.

Hope this will Help

Regards

Himanshu

Skype himanshu_sethi

Not applicable
Author

Hi

Thanks for your reply.  I understand how to change the dimension colour using an expression.  My query is how to check the 'Score' for each individual dimension value in the list. If I add this expression to the dimension then the whole list turns 'Red'.

Thanks,

Not applicable
Author

Same can be applied in dimmension as well, try the same in dimmension

Regards

Himanshu

Skype- himanshu_sethi