Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
ivan_wilson
Regular Visitor

Conditional formatting levels in a matrix visual based on filters

I have a data set that includes up to 4 levels of parent/child relationships. I've used the information at https://www.daxpatterns.com/hierarchies/ to set up the relationships. Each row also has a boolean field called Important. This can be set at any level in the hierarchy.

 

I have a matrix visual that displays the data in a hierarchy. I have set up a slicer for the Important field. The matrix visual displays parent rows that that are not flagged as important if it has a child row that is flagged as important. This is the behaviour I want.

 

Now I'd like to apply conditional formatting to highlight rows that are tagged as important, to distinguish them from rows that aren't tagged as important but have an important child row.

 

IDParent IdTypeNameImportant
1 InitiativeSell house1
2 InitiativeBuy house 
31EpicPaint house 
41EpicFix windows1
51EpicLandscape garden 
62EpicFind new house 
72EpicGet mortgage 
83TaskPrepare walls 
93TaskBuy paint 
104TaskReplace broken windows 
114TaskFix window locks 
125TaskCut lawn1
135TaskPlant flowers 
146TaskShortlist properties1
156TaskGet property inspection 
166TaskAttend auction 
177TaskUpdate finance information 
187TaskSave money 
197TaskVisit bank 

 

The bullet points below show's the hieararchy filtered to just the important items (including parents). I assume I need to create a measure that will identify if the row is set to important or not.

 

  • Sell House
    • Fix windows
    • Landscape Garden
      • Cut lawn
  • Buy house
    • Find new house
      • Shortlist properties

Is this possible?

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @ivan_wilson 
If I understood you correctly you need to apply conditional formatting to row heathers than 

Unfortunately, we don't have a conditional formatting functionality on matrix rows.

There is an idea about this issue please vote for it here:
https://ideas.fabric.microsoft.com/ideas/idea/?ideaid=b02bce75-4528-ec11-b76a-281878e62223

 

This option is available at inforiver visuals, but for pay:
https://community.inforiver.com/tips-tricks/post/conditional-formatting-of-whole-table-rows-using-in...

https://www.youtube.com/watch?v=WF7fCAmjjZc


But you can apply it to the values.
You can create a flag measure with dax :
flag = if max('your table'[important] = 1 , 1,0) 
and use this measure for the rule on conditional formatting

Ritaf1983_0-1706670848330.png

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

1 REPLY 1
Ritaf1983
Super User
Super User

Hi @ivan_wilson 
If I understood you correctly you need to apply conditional formatting to row heathers than 

Unfortunately, we don't have a conditional formatting functionality on matrix rows.

There is an idea about this issue please vote for it here:
https://ideas.fabric.microsoft.com/ideas/idea/?ideaid=b02bce75-4528-ec11-b76a-281878e62223

 

This option is available at inforiver visuals, but for pay:
https://community.inforiver.com/tips-tricks/post/conditional-formatting-of-whole-table-rows-using-in...

https://www.youtube.com/watch?v=WF7fCAmjjZc


But you can apply it to the values.
You can create a flag measure with dax :
flag = if max('your table'[important] = 1 , 1,0) 
and use this measure for the rule on conditional formatting

Ritaf1983_0-1706670848330.png

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.