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

British Summer Time Problem

I have a PowerApp and a Flow connected to it, which sends an email to the company with the data pulled from a SharePoint List.

 

There are a few Date columns in the list, however since we changed to BST (+1Hour) all the dates are now an hour behind (even though the correct date/time shows in the form).

 

I have read a few posts regarding TimeZoneOffset but I can't seem to apply it to my application.

 

For simplicity I will focus on one data card called: 

 

"Event_x0020_Date_x0028_s_x0029__"

 

The update on this card is:

 

"MasterDate.SelectedDate + Time(Value(MasterHour.Selected.Value), Value(MasterMinute.Selected.Value), 0)"

 

On the Flow, the formula used to display the date on an email is:

 

formatdatetime(item()?['Event_x0020_Date_x0028_s_x0029__'],'dddd dd MMMM yyyy H:mm')
 
Any help anyone can offer would be greatly appreciated
1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Re: British Summer Time Problem

Hi @jpacettf ,

 

It is a known issue for PowerApps and Microsoft Flow.

 

PowerApps will convert date time values to the local value. On PowerApps, when you set the DateTimeZone property of a Date picker control to UTC, it assumes that the input value is in UTC, the control will then display the local value to the user.

 

In your scenario, let’s say you’ve input date time value of ‘01/05/2019 00:00 UTC’, PowerApps recognizes that your timezone is BST and subtracts 1 hour to show the input value in your local time. The displayed date time value is “30/04/2019 23:00”.

 

Please consider using function addhours to add 1 hour to the date time value.

 

More details about addhours, please check it at here:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#a...

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Community Support
Community Support

Re: British Summer Time Problem

Hi @jpacettf ,

 

It is a known issue for PowerApps and Microsoft Flow.

 

PowerApps will convert date time values to the local value. On PowerApps, when you set the DateTimeZone property of a Date picker control to UTC, it assumes that the input value is in UTC, the control will then display the local value to the user.

 

In your scenario, let’s say you’ve input date time value of ‘01/05/2019 00:00 UTC’, PowerApps recognizes that your timezone is BST and subtracts 1 hour to show the input value in your local time. The displayed date time value is “30/04/2019 23:00”.

 

Please consider using function addhours to add 1 hour to the date time value.

 

More details about addhours, please check it at here:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#a...

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
ADMCharles Advocate II
Advocate II

Re: British Summer Time Problem

So are you saying that we should edit our flows every 6 months to remove the BST logic?

What about in a system where the date is not representative of the current time?

 

The only way I see this being a feasible workaround in flow is if you check the date value is within the range of the timezone offset for the summer time and then add an hour. Which is horrific to implement in flows logic.

SharePoint Workflows run in the SharePoint's locale so it avoids this problem.

 

For all who have to deal with BST or any other timezone with a shifting summer time I recommend using Bing's Timezone API since it's free. You can then convert to the required timezone; do your date operations and then convert it back.

Hopefully this point will be moot next year when most countries abandon Summer Timezone offsets. I'll be much closer to sanity then.

danb2593
New Member

Re: British Summer Time Problem

I think I've found a solution in this expression:

 

convertFromUtc(triggerBody()?['values']?['submiteta'], 'GMT Standard Time', 'dd/MM/yyyy HH:mm:ss')

 

In your context:

 

convertFromUtc(item()?['Event_x0020_Date_x0028_s_x0029__'], 'GMT Standard Time', 'dddd dd MMMM yyyy H:mm')

 

'GMT Standard Time' does seem to be adding an hour at the moment, however while I have every faith it will make the switch in October I've a bit of a wait to test that..

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (7,288)