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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patching selected date...
Power Apps
Unanswered

Patching selected dates and times to a sharepoint list.

(0) ShareShare
ReportReport
Posted on by 7

Greetings everyone, 

 

I need some help with figuring out how to push a selected date and time out of powerapps into a sharepoint date column. 

 

I have 4 inputs that I am using to gather the information in the app: 

A date picker for the date.

3 separate dropdowns: 1 that contains 1-12 for the hour, 1 that contains 1-60 for the minutes, and the last contains AM/PM.

DMCornelius_0-1643726582144.png

 

I then put a label on the screen and set its Text property to:

DMCornelius_1-1643726675030.png

 

The label returns what I would expect: 

DMCornelius_2-1643726760740.png

 

I put the above code into a patch function, and it successfully pushes a datetime through. However, it is not pushing the correct time. 

 

DMCornelius_4-1643726978676.png

 

So I have 2 problems:

1.) My timezone is off. Is there a way to set the timezone within powerapps? (I am in EST)

2.) My minutes aren't going through. 

 

Any help at all would be greatly appreciated!

 

Thanks everyone, and have a great day. 

 

 

 

 

 

Categories:
I have the same question (0)
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @DMCornelius 

    What is your formula for your Patch function?

  • DMCornelius Profile Picture
    7 on at
    Patch(IncidentReports,
     Defaults(IncidentReports),
    {Title: First(ReportIDNumber).ID},
    {Unit:User().FullName},
    {CompletedDate: Today()},
    {IncidentDate: DateTimeValue(IncidentDatePicker.SelectedDate & " " & IncidentTimeHour.Selected.Value&":"&IncidentTimeMinute.Selected.Value&" "& IncidentTimeAMPM.Selected.Value)},
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @DMCornelius 

    Formula looks good.  But (beside the time difference - which is a list setting, not a PowerApps issue) the minutes are off.  So what is the Items property of the IncidentTimeMinute control?

  • DMCornelius Profile Picture
    7 on at

    It is just a manual list of the numbers 1-60, as follows:

     

    ["1","2","3","4","5","6","7","8","9","10","11","12","13","14","15","16","17","18","19","20","21","22","23","24","25","26","27","28","29","30","31","32","33","34","35","36","37","38","39","40","41","42","43","44","45","46","47","48","49","50","51","52","53","54","55","56","57","58","59","60"]

     

    I appreciate your help with this!

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @DMCornelius 

    So that Items list will cause some issues in the single digit minutes conversion.

    Change that Items to:  ForAll(Sequence(60, 0), Text(Value, "00"))

    This will provide the proper set of minutes in the proper format.

     

    Now...combining your issues together to explore:

    There is no reason that I can tell based on your post image as to why 7:42 AM EST would convert to 4:00 PM.  That is a (beside the minutes) 9 hour difference.  Normally, for EST you would only see a 5 hour difference based on UTC.

    So - what is the regional setting of your list?  And, we still need to determine why your minutes are not correct.

  • saranya29 Profile Picture
    4 on at

    Same error occurs for me , any suggestion would greatly appreciated

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 316 Most Valuable Professional

#2
11manish Profile Picture

11manish 242

#3
Valantis Profile Picture

Valantis 198

Last 30 days Overall leaderboard