Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
Sorry for this very simple question but, I have completely ran out of ideas.
I have set up an advanced card with a measure that returns a calculation alongside an up or down arrow (see below).
Unfortunately I need to use conditional formatting, but I can’t get it to work with this measure. I am looking for a result of >0 = green & <0 = red. I have set the parameters of the 'conditions' options, but the advanced card does not change.
Looking at the measure, the format appears to be set as "text", and the option to change to "whole number" is greyed out. I suspect this is why the conditional formatting isn’t working?
Can this format be changed? If not, is there a way to display a number with an arrow in an advanced card with the conditional formation below?
>0 = green
<0 = red
Help as always is massively appreciated,
CF
Solved! Go to Solution.
@Anonymous , refer if these can help
Color Measure - Conditional formatting
https://radacad.com/dax-and-conditional-formatting-better-together-find-the-biggest-and-smallest-numbers-in-the-column
https://docs.microsoft.com/en-us/power-bi/desktop-conditional-table-formatting#color-by-color-values
https://exceleratorbi.com.au/conditional-formatting-using-icons-in-power-bi/
https://community.powerbi.com/t5/Desktop/FORMAT-icon-set-for-use-in-a-data-card/td-p/811692
@Anonymous , refer if these can help
Color Measure - Conditional formatting
https://radacad.com/dax-and-conditional-formatting-better-together-find-the-biggest-and-smallest-numbers-in-the-column
https://docs.microsoft.com/en-us/power-bi/desktop-conditional-table-formatting#color-by-color-values
https://exceleratorbi.com.au/conditional-formatting-using-icons-in-power-bi/
https://community.powerbi.com/t5/Desktop/FORMAT-icon-set-for-use-in-a-data-card/td-p/811692
Yeah, it was my bad. The "&" in the measure automatically converts the format to string. The correct measure should have been just:
Format = IF([Count of Cat]>0,0,1)
But I'm happy you got it sorted!
/ J
Your measure is returning arrows which are bound to text format. If you create another measure,
Format = [Last Month total]-[Count of Cat]&IF([Count of Cat]>0,0,1)
You can then use this measure to conditionally format your "Total" measure.
Add you "Total" measure to the visual, apply conditional formatting, change the based on field value from "Total" to "Format".
This should allow you to get the correct colors on your arrows.
/ J
Hi there,
Massive thanks for taking your time to help.
I have created another measure as below:-
Format = [Last Month total]-[Count of Cat]&IF([Count of Cat]>0,0,1)
I have also added my 'total' measure to the visual.
However when adding conditional formatting to the 'based on field' value am unable to select the measure 'format'.
Again it looks like the 'format' measure is bound to text format, as i am unable to change it whole number.
I am obviously doing something very stupid (it's been a long day). Any idea what i am doing wrong here?
Thank yoouuuuu
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
81 | |
66 | |
58 |
User | Count |
---|---|
151 | |
121 | |
104 | |
87 | |
67 |