Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have created a combochart in my mashup following this tutorial :
Is there a way to set a specific color for each measure, without using a global theme for the Qlik app ?
Thank you
Hi there,
In order to override the default theme color pallet, you will have to set the color properties of the chart from 'auto:true' to 'auto:false' & set 'mode: byMeasure'. This is what the property panel looks like in the native product:
From API perspective, it looks like this (same use case):
For more details read here:
https://help.qlik.com/en-US/sense-developer/May2021/Subsystems/Mashups/Content/Sense_Mashups/Create/...
Thank you for your reply.
From my understanding, mode: byMeasure allows to set colors depending on the measure value.
That’s not exactly what I want : I want to be able to change the color of all the values of one measure.
For example, if I have one set of bars, and one line, I would like to change the colors of :
- the bars : red (same color for all bars)
- the line : blue
That’s similar to the behavior when “Multicolored” is selected, except I want to customize the colors.
Thanks
Now I understand your question better, thanks for clarifying.
What you need to do is
When examining the chart properties, you see that under color object - auto:false, mode:"primary" (also try mode:"multicolored" instead) and useBaseColors:"measure"
Hi,
Thank you for your time.
Sadly, this is not an option for me, since that would force me to create one master measure for each chart.
I guess I should add more context to what I’m trying to achieve :
I’ve managed to replicate the original object configuration/appearance, it only lacks the colors now…
I have also tried to set the “color” property for the measures (set inline in the “cols” of the combochart), but this didn’t seem to do anything.
If there is an alternative way to achieve what I’m trying to do, I will gladly take it !
Thank you