Don't miss your chance to take the Fabric Data Engineer (DP-600) exam for FREE! Find out how by attending the DP-600 session on April 23rd (pacific time), live or on-demand.
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
I have a decomposition tree set up and have conditional formatting on the values so they turn either red or green if one of the columns is yes or no.
Then i have a count of people in another column. The problem that I have is that in the cells that are zero, it stays grey. I want it to go red. Is there a way around it.
Here is my conditional format code I used in the measure.
Colour Code Measure = IF (
ISBLANK('datasource'[Measure]),"Red",
(SWITCH(
TRUE(),
SELECTEDVALUE('datasource'[Yes/No]) = "Yes", "Green",
SELECTEDVALUE('datasource'[Yes/No]) <> "Yes", "Red"
))
)
I did a bandaid fix for this. I changed the base colour to the same red, since all of the ones with no values would be a no anyways.
@Rostanga where are you using yes/no column?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
This is the set I created for this sample decomp tree. Just kept it small.
The yes/no column is only used in the measure that was created for the colour coding of the data boxes in the tree
@Rostanga try this:
Colour Code Measure =
IF (
[Measure] = 0,
"Red",
(
SWITCH (
TRUE (),
SELECTEDVALUE ( 'datasource'[Yes/No] ) = "Yes", "Green",
SELECTEDVALUE ( 'datasource'[Yes/No] ) <> "Yes", "Red"
)
)
)
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Unfortunately still staying grey.
@Rostanga are you forcing measure to show 0 instead of blank ()?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@parry2k the data source has zero's in it.
If i put those as null in power query then they disappear completely from the visual.
But i need them to show as zero, but then as those would be non-compliant (or they are a no), I need those to also show as red. I only want the ones that are yes to be green.
I haven't added any other parts to the measure to force it.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 48 | |
| 45 | |
| 41 | |
| 20 | |
| 17 |
| User | Count |
|---|---|
| 69 | |
| 64 | |
| 32 | |
| 31 | |
| 27 |