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

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.

Reply
rahuldas_vgm
Helper I
Helper I

HELP NEEDED WITH CONDITIONAL FORMATTING of Matrix visual

Hello,

I want certain cells of matrix visual to have background colours. On my column I have a calculated column: Current Payment Band and on the Rows I have another Calculated column:Last Payment Band. I would want them to be coloured: values depicting 0 should be yellow, 1 should be Red and 2 should be Green (the 0,1,2, are not actual values but to help identify the cells that needs the respective colour). The matrix looks like:

  a   b   c   d

a 0  2    2   2

b 1  0   2    2

c  1  1   0    2

d  1  1   1    0

Any help with how to put background colour on the basis of the row and column header would be of great help!

Thank You in advance.

3 REPLIES 3
rahuldas_vgm
Helper I
Helper I

Thank You @selimovd for your help. The simple conditional formatting of background is not allowing me to change the colors of the cells on the basis on the row and column header values. Example:

The cells corresponding to a,b,c,d segment for both row and column need to have yellow colour and the cells to the right of yellow colour shading should be green and the cells to the left should be red.

What it is allowing me to do is change the colors on the basis of the values.
Is there any way I can make the cells take the desired colour on the basis of values of the column and row header? Like yellow when both row and column header are same, it will go yellow
        Green when row header is a and column header is b,c,d.

        Red when row header is c and column header is a,b.
Thank you again for your help.
Looking forward to your reply.

Best,

Rahul

Hey @rahuldas_vgm ,

 

sure, that's also possible. You can create a measure that is checking for the values in the row and column. Based on the result you can return a color within the measure.

 

This measure you can use then as color for the whole row:

Conditional table formatting in Power BI Desktop - Power BI | Microsoft Docs

Dynamic Conditional Formatting In Power BI with DAX - YouTube

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

 

selimovd
Super User
Super User

Hey @rahuldas_vgm ,

 

you can do that simple with conditional formatting of the background.

Check the following article on how to do that:

Conditional table formatting in Power BI Desktop - Power BI | Microsoft Docs

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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