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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
PPStar
Helper V
Helper V

Format DateTime.LocalNow()

Hello, 

I have a dataflow and i need to include the last refresh date in that dataflow. 

I created a new blank query and entered the following code : 

DateTime.LocalNow()
 
This correclty returns me the date time now. 
 
However, the users who will be using this dataflow are all based in the united states. 
 
How can i format this 
DateTime.LocalNow() to show as mm/dd/yyy hh:mm:ss 
Or, just to show as 14th Febuary 2024 10:01:22
 
Thanks 
1 ACCEPTED SOLUTION
katemarkoska
Frequent Visitor

Hi @PPStar 
You do not need to format anything. This function returns a datetime value set to the current date and time on the system.
So if the users are in the US and the region on their system is set to US it will automatically format as mm/dd/yyy hh:mm:ss.

View solution in original post

3 REPLIES 3
katemarkoska
Frequent Visitor

Hi @PPStar 
You do not need to format anything. This function returns a datetime value set to the current date and time on the system.
So if the users are in the US and the region on their system is set to US it will automatically format as mm/dd/yyy hh:mm:ss.

Thanks Kate. I just tested this and you are correct. Thank you. 

Idrissshatila
Super User
Super User

Hello @PPStar ,

 

check this video https://youtu.be/eH9dHfNG8kg?si=lWwD8RbJhb7Dxnv2

 



Did I answer your question? Mark my post as a solution! Appreciate your Kudos
Follow me on LinkedIn linkedIn
Vote for my Community Mobile App Idea

Proud to be a Super User!




Helpful resources

Announcements
Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

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.