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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Anonymous
Not applicable

Conditional Formatting: Number to Text

I have a column called "Projected Hour Variance" that shows a percentage. I have this on a card visual, but instead of the percentage appearing, I want to show text OR show a red/yellow/green dot.

 

For example:

If the value is between -10% and 0%, I want text to appear as "Within Budget" OR have a green dot.

If the value is more than 10%, I want text to appear as "Over Budget" OR have a red dot.

 

How do I do this? 

1 ACCEPTED SOLUTION
v-xuding-msft
Community Support
Community Support

Hi @Anonymous ,

 

Please try this:

v-xuding-msft_0-1601967455308.png

 

Or create a measure:

Measure = 
var pro = MAX('Table'[Projected Hour Variance])
return
IF( pro <=0 && pro >= -0.1,"Within Budget",IF(pro>=0.1,"Over Budget",""))

v-xuding-msft_1-1601967610560.png

 

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-xuding-msft
Community Support
Community Support

Hi @Anonymous ,

 

Please try this:

v-xuding-msft_0-1601967455308.png

 

Or create a measure:

Measure = 
var pro = MAX('Table'[Projected Hour Variance])
return
IF( pro <=0 && pro >= -0.1,"Within Budget",IF(pro>=0.1,"Over Budget",""))

v-xuding-msft_1-1601967610560.png

 

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Tahreem24
Super User
Super User

@Anonymous ,

Try a below DAX measure:

Final Output = SWITCH(TRUE(),AND([Projected Hour Variance]>-10,[Projected Hour Variance]<=0),"Within Budget","Over Budget")
See this screen shot of expected output.
 
1.PNG
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard
amitchandak
Super User
Super User

@Anonymous , You can create a color measure and use UNICHAR to display

 

example

Color Year = if(FIRSTNONBLANK('Table'[Year],2014) <=2016,"lightgreen",if(FIRSTNONBLANK('Table'[Year],2014)>2018,"red","yellow"))

 

refer these two

https://community.powerbi.com/t5/Desktop/FORMAT-icon-set-for-use-in-a-data-card/td-p/811692

https://exceleratorbi.com.au/conditional-formatting-using-icons-in-power-bi/

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

How or where do I add these formulas?

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.