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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply

Define date format within a measure for a card

So I am quite new to Power Bi and have hit a snag.  when i include a measure in a string, the date format is wrong.  I have checked my regional settings and they are set to Australia.  I have tried changing to UK but then it mucks up all of data import and i get an error message.  So i thought the best way to fix this is to add date formatting to my card string measure but i'm not quite sure how to do it.  (I want the formatting in the string measure card below to be the same as that in the 'date of highest temperature' card. ie  21/07/2016.  I have included the two measures below, and because one of them reflects ok in the card, i think i just need to add some sort of formatting statement in the string measure.  Can someone help?  (I think that all of my background formatting in my date tables is correct)

 

Capture.JPG

 

 

 

Here are my measures:

String measure for card = "Your hottest birthday was "&[Highest temperature selected previous date]&" degrees C on "& [Date of highest temperature selected previous date]
 
Date of highest temperature selected previous date =
CALCULATE(FIRSTDATE(Dates[Date]),
FILTER(VALUES(Dates[Date]),
[Highest temperature selected previous date]=
CALCULATE([Highest temperature selected previous date],
VALUES(Dates[Date])
)
)
)
 

 

 
2 ACCEPTED SOLUTIONS
Mariusz
Community Champion
Community Champion

Hi @tigersandblues 

 

You can use FORMAT( yourExpresion, "dd/mm/yyyy" ) fdunction, obviusly adjust the format to Australia

https://docs.microsoft.com/en-us/dax/custom-date-and-time-formats-for-the-format-function

 

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

View solution in original post

amitchandak
Super User
Super User

@tigersandblues , Try like

String measure for card = "Your hottest birthday was "&[Highest temperature selected previous date]&" degrees C on "
 & format([Date of highest temperature selected previous date],"dd/mm/yyyy")
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

View solution in original post

5 REPLIES 5
amitchandak
Super User
Super User

@tigersandblues , Try like

String measure for card = "Your hottest birthday was "&[Highest temperature selected previous date]&" degrees C on "
 & format([Date of highest temperature selected previous date],"dd/mm/yyyy")
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

Thanks @amitchandak - that is perfect - exactly what i was looking for.😀

prob should have been able to work it out myself, but i need to get my head around all this 'nesting' business!

harshnathani
Community Champion
Community Champion

Hi @tigersandblues ,

 

See if this video helps.

 

https://www.excelcampus.com/powerquery/power-query-date-errors-settings/

 

Regards,

Harsh Nathani

Thanks for that @harshnathani .  I did have a go at that but it made my file crash when it tried to update.  

 

 

Mariusz
Community Champion
Community Champion

Hi @tigersandblues 

 

You can use FORMAT( yourExpresion, "dd/mm/yyyy" ) fdunction, obviusly adjust the format to Australia

https://docs.microsoft.com/en-us/dax/custom-date-and-time-formats-for-the-format-function

 

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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