cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
CarlosAguilar
New Member

Timezone calculation discrepancy with sharepoint data

I have a Gallery List and a form that is saving data to a sharepoint list. I have two fields Start_Date and End_Date. Both date pickers are configured with local time zone and my computer and devices are configured with timezone UTC - 6 and the sharepoint site it's also configured with UTC -6.

 

There are two errors:

 

If the field is configured in Local TimeZone, the data saved should have the same value in the sharepoint list as it's send from the picker that also has the same timezone. I have used the TimeZoneOffset to be sure that the date is in UTC -6 when the users selects it. Some how the patch function, that it takes both values from the form, changes the timezone to UTC. I have managed to work around this with adding this line of code:

 

Start_Date : DateAdd (Form2.Updates.Start_Date,-TimeZoneOffset(Form2.Updates.Start_Date), Minutes )

 

But that shouldn't be necessary.

 

The other issue is that when I go back to the Gallery list it shows the hours off by 1 hour. I have added a refresh button to update the datasource(sharepoint list). When I hit that button, the hours are showed correctly(without any other changes to code). That means that after saving the data from the form, the list is showing local calculations of the dates that are incorrect.

 

Both issues were not present a couple of weeks ago, but they have appear after the timezoneoffset capabalities were added.

 

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions

Problem has been solved in powerapps version 650. Both work arounds had been removed from my app and it's working like a charm. Thanks!

View solution in original post

3 REPLIES 3
v-micsh-msft
Community Support
Community Support

Hi @CarlosAguilar,

 

 

Thanks for the feedback.

I will forward this once issue has been confirmed from my side.

 

Regards,

Michael

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

Thanks, let me know any feedback or if you need more information!

Problem has been solved in powerapps version 650. Both work arounds had been removed from my app and it's working like a charm. Thanks!

View solution in original post

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (1,237)