UTCNow

How to Use the Power Fx UTCNow  Function in Power Apps

Understanding UTC

Before we dive into the details of UTCNow, it’s essential to understand what UTC is. UTC is the primary time standard used worldwide for coordinating time across different time zones. It’s based on the atomic clock and is considered highly accurate. However, the primary advantage of UTC is that it’s the standard time that all time zones are based on. So, if you want to track or coordinate time across different time zones, UTC is the way to go.

What is UTCNow?

UTCNow is a function in the Power Fx language that returns the current Universal Coordinated Time (UTC) in the format of a date/time value. It’s a powerful function that can be used in a variety of scenarios, such as tracking and recording the exact time an event occurred or calculating the duration between two events.

How to Use UTCNow in Power Apps

Using UTCNow in Power Apps is relatively straightforward. You can use it in a formula to display the current UTC time in a label or text box, for example.

To use the UTCNow function in your Power App, follow these steps:

1. Open the app where you want to use the UTCNow function.

2. Navigate to the screen where you want to display the UTC time.

3. Select the control where you want to display the UTC time.

4. In the formula bar, type the following formula:


UTCNow()


5. Press Enter.

The UTCNow function will return the current UTC time in the format of a date/time value. You can now use this value as needed in your app.

Using UTCNow with Other Functions

UTCNow can be used in conjunction with other Power Fx functions to perform even more complex tasks. For example, you can use it with the DateTimeZone function to convert the UTC time to a specific time zone.

To convert the UTC time to a specific time zone, follow these steps:

1. In the formula bar, type the following formula:


DateTimeZone(UTCNow(), "Eastern Standard Time")


2. Press Enter.

The DateTimeZone function will convert the UTC time to Eastern Standard Time and return the value in the format of a date/time value. You can replace “Eastern Standard Time” with any time zone you want to convert the UTC time to.

In conclusion, using the Power Fx UTCNow function in Power Apps is essential if you need to track or coordinate time across different time zones. It’s a powerful function that can be used in a variety of scenarios, and it’s relatively easy to use. By following the steps outlined in this article, you can quickly begin using the UTCNow function in your Power Apps and take advantage of its many benefits.

Power Apps Training Courses by G Com Solutions (0800 998 9248)