Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I'm relatively new to Qlik Sense and am using the desktop version. I've used a KPI chart to show the latest months info and to also add the month on month / year on year variance as part of the second measure (see picture)
I am having trouble adding conditional formatting to the 2nd measure - ie I want it to be red if less than 0 and green if not.
The current expression for the 2nd measure is:
num(($(V.Last Month Net Sales Value)-$(V.One Before Last Month Net Sales))/$(V.One Before Last Month Net Sales),'#.#%')
& '/' &
num(($(V.Last Month Net Sales Value)-$(V.Last Month Last Year Net Sales Value))/$(V.Last Month Last Year Net Sales Value),'#.#%')
but I can't seem to add any conditional colours to it that work.
Any suggestions welcome!
Thanks
Sarah
Hi Pradosh
I tried that, but it comes up with a message saying 'Unable to change the properties because there is an error in the expression'.
I think its as I have 2 calculations within the second measure (effectively trying to create a third measure) so was looking for an alternative solution if possible.
Thanks
Sarah
tried this in simple kpi
entered the value 10 in secondary expression
KPI-> Appearance -> color ->second -> check the color as red -> check conditional colors -> add limit -> click on the right side color -> change it to green-> add 0 in the expression box -> done
now chnage value to less than 0 and it will turn red.
Tried it, it's working.
Hi Pradosh
I've got it to work too for a simple calculation and have done so on a previous tab within my dashboard. What I want, though, is to have the text within the 2nd measure change colour depending on their value.
eg First Measure = £20M, Second Measures = -0.9% MoM in Red and potentially +0.5% YoY in Green.
Am I getting the error as the way I have currently written it turns it into a text format by adding the & '/' & within the expression? If so, is there a better way of writing it?
Thanks
Sarah