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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Luquiluk
New Member

color Dynamic Format

I have the following DAX composition in dynamic format, but I can't get the negatives to be red

 

VAR AA = [AA]

var BB = [BB]

var _Formato_AA = FORMAT(AA,"#0, K")

var _Formato_BB = FORMAT(BB,"#0, K;[Rojo] -#0, K","es-ES")

VAR _def = UNICHAR(34) & _Formato_AA & UNICHAR(34)&"  ("&_Formato_BB&")"

return _def & UNICHAR(34)

 

 

4 REPLIES 4
Luquiluk
New Member

I try to make a waterfall graph that shows me the two data and that the bars have the size of the data of A and has a sequence of the data of B and the color of the column conditional on B

mark_endicott
Super User
Super User

@Luquiluk - you can't set the colour of a result inside FORMAT() you need to use conditional formatting on the measure / column.

 

This article has some good pointers on it: https://radacad.com/dax-and-conditional-formatting-better-together-find-the-biggest-and-smallest-num...

 

If this works, please accept as the solution. 

The problem is that it is text of two measures AA and BB, I want that when BB is negative only the BB in red comes out

1100K (18K)

2200K (-25K)

 

@Luquiluk - Yep, not going to happen. Suggest you find a different way to visualise this. 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

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.