Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi , in my qv model i have classes , and for each there is a unique code .
by selection - its possible that the relevant code will be :
10,98,111,112,320 .. or 10,11,34,320,441,501 .. or 11,12,13,111,112,113,333,444 ..
the thing is that i need to set same colors for the same codes all over the model - at all tabs , all objects ,
so the first code - no matter the value is - will be green, the socond will be red , the third blue , and so on ....
( according to the colors - Data Apearance palate )
How can I do this in the simplest way? THANS.
Maybe with:
LOAD ...
Autonumber(code) as ColorNumber
...
And set color as: Color(ColorNumber)
Another option that can work: in object properties ->Color tab, check the box for 'Persistent colors'
Hi, can you try with?:
Color(FieldIndex('FieldName',FieldName))
Maybe it doesn't work's as expected with repeated values in the same field and you need to add a "RowNo() as ColorValue" in script, and use this field to assign different colors to repeated values.
hi , and thanks , it works partially ,
the case is more than that , WHY ?
1 - Because in the chart i have the codes dimension AND another month dimension .
2 - Because there are many code values , and the color exprasion give an outcome bigger than 18 - while in the chart color palate there isaonly 18 ..
i think those 2 reasons spoils our goal. please see the attach file , THANKS!!
Hi, there are 20 colors: 19th is 'Others' and 20th is 'Totals'. When you reach color 21 it starts again, so Color(21)=Color(1).
I don't know why it's painting a yellow bar, can you confirm that color configuration in the 2nd chart is the same than in the first?
I confirm, the colors belong to both graphs.
is there a way to give running number to the relevant CODES ? it can help
Maybe with:
LOAD ...
Autonumber(code) as ColorNumber
...
And set color as: Color(ColorNumber)
Another option that can work: in object properties ->Color tab, check the box for 'Persistent colors'
hi , it is a good solution!! THANKS!!
I tried to accept as solution - but i get this massage :
The page you are trying to access was not found. Please check your URL for typos and try again.
do you know who can help me - cant find the manager email ..
I will mark the other comment as correct solution, but I wanted to throw out one more Design Blog post that may be of some further help too, it is along the lines of the other post, but may give you some further clarity on things!
https://community.qlik.com/t5/Qlik-Design-Blog/Colors-in-charts/ba-p/1475280
Cheers,
Brett