cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
BLD65
Resolver I
Resolver I

Card Visual Conditional Formatting

Thanks to all who respond.

 

I need help creating this measure:  I have 3 cards showing totals for 2021, 2020, 2019. I would like to have the font color change to red or green based on the previous year total. So if year 2020 amount was greater than 2021 change to 'red', if less than change to 'green'.

 

Table name = 'Sheet1'

Field name = 'Amount'

Field name = 'YEAR'

 

Any ideas?

Thanks-BLD

 

1 ACCEPTED SOLUTION
KerKol
Super User
Super User

You'll need to use a different KPI Card visual. There are a few options in AppSource.

 

You could create your own card visual using Smart Narratives:

KerKol_0-1643060316335.png

And change the colour of the font using this trick:

Smart Narratives and Conditional Formatting in Power BI? Yes please! - Guy in a Cube





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

Proud to be a Super User!




View solution in original post

3 REPLIES 3
KerKol
Super User
Super User

You'll need to use a different KPI Card visual. There are a few options in AppSource.

 

You could create your own card visual using Smart Narratives:

KerKol_0-1643060316335.png

And change the colour of the font using this trick:

Smart Narratives and Conditional Formatting in Power BI? Yes please! - Guy in a Cube





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

Proud to be a Super User!




Thank you, great idea.

BLD

johnbasha33
Helper IV
Helper IV

@BLD65 HI, 

 

We cant dynamically change the font colour using Card, instaed use table for each value and you need to create 3 different measures where you need to use switch statement dax1 > dax2 then "Hex code of Red" like that..

Regards,
John Basha Mattipati,
https://www.linkedin.com/in/john-basha-mattipati-06812980/


Helpful resources

Announcements
June 2022 update 768X460.jpg

Check it out!

Click here to read more about the June 2022 updates!

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power BI Dev Camp Session 23 768x460.jpg

Check it Out!

Mark your calendars and join us on Thursday, June 30 at 11a PDT for a great session with Ted Pattison!

June 20 episode 7 with aka link 768x460.jpg

The Power BI Community Show

Join us on June 20 at 11 am PDT when Kim Manis shares the latest on Azure Synapse analytics, the Microsoft Intelligent Data Platform, and notable Power BI Updates from Microsoft Build 2022.

Top Solution Authors