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 / Patch text value into ...
Power Apps
Unanswered

Patch text value into Date type column in sharepoint

(1) ShareShare
ReportReport
Posted on by 162

Hi, 

 

    I have create Calendar application to help my team for mark a date to WFH but I facing a problem that when I click date that I want and need to update to SP it can't update cause I've using patch with Label into Date type in SP.

 

  The reason I need to do this because after user has selected their date I'll use it to show in calendar. 

 

nitisak_0-1686195925916.png

 

Categories:
  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @nitisak ,

     

    You could convert the string to datetime value by the DateTimeValue function .

     

    Best Regards,
    Bof

  • nitisak Profile Picture
    162 on at

    Hi @v-bofeng-msft 

     

    Where can I put the code into in text label ?

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @nitisak ,

     

    Could you please show me the submit button's OnSelect property ?

     

    Best Regards,
    Bof

  • nitisak Profile Picture
    162 on at

    Hi @v-bofeng-msft 

     

    Sorry for late reply. Here's my code. 

     

    Patch('Next Gen Calendar',Defaults('Next Gen Calendar'),
    {

    NameofUser: User().FullName,
    Status:{Value:"Entering Office"}

    }
    );
    Clear(colDates2);
    Navigate(Screen2,ScreenTransition.UnCover)

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @nitisak ,

     

    Please try:

     

    Patch('Next Gen Calendar',Defaults('Next Gen Calendar'),
    {

    NameofUser: User().FullName,
    Status:{Value:"Entering Office"},

    DateTimeColumn:DateTimeValue(LabelName.Text)

    }
    );
    Clear(colDates2);
    Navigate(Screen2,ScreenTransition.UnCover)

     

    Best Regards,

    Bof

  • nitisak Profile Picture
    162 on at

    Hi @v-bofeng-msft

     

    I forgot to tell you that data selected has store in Collection before add

  • nitisak Profile Picture
    162 on at

    Hi @v-bofeng-msft 

     

     

    It's worked if I choose only one record but my propose is allow users to selecte mutiple record and add to SP as well. 

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @nitisak ,

     

    Show me the collection please.

     

    Best Regards,

    Bof

  • nitisak Profile Picture
    162 on at

    hi @v-bofeng-msft   

     

    Please see.

    nitisak_0-1686724189813.png

     

     

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @nitisak ,

     

    What do these numbers represent? Seconds? If so, what is the start time?

     

    Best Regards,

    Bof

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 381 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 340

#3
WarrenBelz Profile Picture

WarrenBelz 187 Most Valuable Professional

Last 30 days Overall leaderboard