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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Laxmanjatoth
Resolver I
Resolver I

How can I use Dax to add blank cells with a coloured background?

I have two queries 
1) How can I use Dax to add blank cells with a coloured background? 
2) how to hide zeros in matrix visuals which is not useful .

3 ACCEPTED SOLUTIONS
rajendraongole1
Super User
Super User

Hi @Laxmanjatoth - you can conditionally format a matrix or table visual to achieve the effect of blank cells with colored backgrounds.

create a DAX measure that returns a blank value.

Measure_Blank = BLANK()

add this measure to your matrix or table wherever you want the blank cells to appear.Set the rule for the cells where the DAX measure returns BLANK() or any other specific condition.
Choose a color for those blank cells.

 

2. You can use a DAX measure that replaces 0 with BLANK()

Measure_HideZero = IF([YourMeasure] = 0, BLANK(), [YourMeasure])

This will display nothing instead of zeros in the matrix.

or You can set rules to format values that are equal to zero. For instance, set the Text color to match the background color for zero values, effectively hiding them.

 

Hope this helps.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





View solution in original post

hello rajendra  basically i tried it , it not working my side  bit requirement different. finally i did it in different way .

View solution in original post

Anonymous
Not applicable

Hi @Laxmanjatoth ,

 

If the problem has been solved, you can accept the answer you found helpful as a solution or share your approach, which will help more people with similar question.

 

@rajendraongole1 Thank you for your reply and contribution to the community.

 

 

Best regards,

Mengmeng Li

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @Laxmanjatoth ,

 

If the problem has been solved, you can accept the answer you found helpful as a solution or share your approach, which will help more people with similar question.

 

@rajendraongole1 Thank you for your reply and contribution to the community.

 

 

Best regards,

Mengmeng Li

rajendraongole1
Super User
Super User

Hi @Laxmanjatoth - you can conditionally format a matrix or table visual to achieve the effect of blank cells with colored backgrounds.

create a DAX measure that returns a blank value.

Measure_Blank = BLANK()

add this measure to your matrix or table wherever you want the blank cells to appear.Set the rule for the cells where the DAX measure returns BLANK() or any other specific condition.
Choose a color for those blank cells.

 

2. You can use a DAX measure that replaces 0 with BLANK()

Measure_HideZero = IF([YourMeasure] = 0, BLANK(), [YourMeasure])

This will display nothing instead of zeros in the matrix.

or You can set rules to format values that are equal to zero. For instance, set the Text color to match the background color for zero values, effectively hiding them.

 

Hope this helps.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





hello rajendra  basically i tried it , it not working my side  bit requirement different. finally i did it in different way .

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors