Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
how can I dynamically get the offset between utc and client.
The follwoing does not work
DateTimeZone.UtcNow()-DateTimeZone.LocalNow())
I want this to result in -4 as I am in EST.
Thank you in advance.
Solved! Go to Solution.
Some areas are offset by hours and minutes, hence the second line:
= DateTimeZone.ZoneHours(DateTimeZone.FixedLocalNow())
+ DateTimeZone.ZoneMinutes(DateTimeZone.FixedLocalNow()) / 60
@ronrsnfld many thanks, this is simply awesome.
Some areas are offset by hours and minutes, hence the second line:
= DateTimeZone.ZoneHours(DateTimeZone.FixedLocalNow())
+ DateTimeZone.ZoneMinutes(DateTimeZone.FixedLocalNow()) / 60
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 19 | |
| 10 | |
| 9 | |
| 8 | |
| 7 |