Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
SunilChauhan
Champion
Champion

change color of values in a list/filter on selection of other list/filter in qliksense

Hi  Team,

 

hope you are doing good.

I have a query below

How change color of values in a list/filter on selection of other list/filter in qliksense.

Example

List 1List 2
IndiaDelhi
IndiaPune
UsWashington
Srilanka Colombo

 

When i select India  Then Delhi and Pune in Green Color,

when I select US then Washington in Blue color

when i slect India and US . then Delhi and Pune in green  and Washington in Blue.

 

Note : we need to achieve this in Qliksense.

Thanks

Sunil

Sunil Chauhan
3 Replies
rubenmarin

Hi, you can add a table with color codes for each country, having data like this:

Cities:
load * Inline [
List 1 	,List 2
Us		,Washington
India	,Delhi
India	,Pune
Srilanka,Colombo
];

Color:
LOAD * Inline [
List 1	,Red,Green	,Blue
Us		,0	,0		,255
India	,0	,192	,0
Srilanka,192,0		,0
];

To add background colors you can use a table object, that allows a background color expresssion like:

If(GetSelectedCount([List 1])>0,RGB(Red,Green,Blue))

rubenmarin_0-1632584652219.png

rubenmarin_1-1632584665995.png

 

SunilChauhan
Champion
Champion
Author

In table box when you select an item then it's hide other values. Where as in filter/ list it will show green and Grey.

My requirement is slight different . I am developed a custom report  where a have two filter pane.

And when I select in first filter pane value associated with it in second filter pane should be colored and when I select in same value in second list box should be green.

What you have done is required in filter pane + when I select then it should work as normal selection we are doing.

 

Thanks

Sunil

 

 

 

Sunil Chauhan
rubenmarin

Hi, filters panels can't be colored by default, you'll need an extension for that. (I don't know if there is any here: https://developer.qlik.com/garden)

You can keep the first filter as a normal filter but for the second you need an object that accepts an expression for background colors.