web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patch date and time wi...
Power Apps
Unanswered

Patch date and time with timezone difference

(0) ShareShare
ReportReport
Posted on by 7

Hello there, I hope you can help me out here, because i'm completely lost. I have an app in powerapps where i patch a datetime picker to a date time column in sharepoint. It patches ok but there is a 4 hours difference between the hour i submitted in the app and the hour that was patched in the sharepoint. Same thing happens with the submission:Now() part of the code. What am I doing wrong?
If you need it , the code for the OnSelect property of the submit button is this: 

Patch(
    'TestList2',
    Gallery3.Selected,
    {
        Status: {Value: "Pending"},
           'Timestamp':DateValue2_1.Value +
                         Time(Value(HourValue2_1.Selected.Value), Value(MinuteValue2_1.Selected.Value),0),
        Submission:Now()
        }
 
Thanks in advance!
Categories:
I have the same question (0)
  • Verified answer
    v-bofeng-msft Profile Picture
    on at

    Hi @Maurizio1 ,

     

    Firstly, let me explain why you encountered this problem.

    The point is timezone. The time in your App is the local time. When the time is saved to SharePoint, it will be converted according to the time zone set by your SharePoint Site. So the time you get is different from the time in the App.

    Secondly, I have two solutions :

    Solution1:Modify the formula

    Submission:DateAdd(Now(),X,Hours),

    Solution2:Change the TimeZone of your SharePoint Site

    Site contents>Site Settings>Site Administration>Regional settings

    vbofengmsft_0-1715215538758.jpeg

     

    vbofengmsft_1-1715215538759.jpeg

     

    Best Regards,

    Bof

  • Maurizio1 Profile Picture
    7 on at

    You rock!! Thanks so much, it worked perfectly!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard