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 / Update SharePoint list...
Power Apps
Answered

Update SharePoint list with timestamp from button in gallery

(0) ShareShare
ReportReport
Posted on by 91

I have created a an app which records the time in the edit form with the formula 

 

UpdateContext({CurrentTime2: Now()});UpdateContext({ButtonClicked2: true}) 

 

for button

and 

 

If(ButtonClicked2, CurrentTime2, Parent.Default)

 

 for text input

 

How to add the same button in Gallery so that i can edit the list from gallery itself

 

 

 

Categories:
  • Digital Profile Picture
    1,207 on at

    Do you want to insert the button into a gallery and then when you click on the button have it patch the SPL directly?

     

    Or do you want the button in the gallery to update a form field which will update the list when submitted?

  • aswin12345 Profile Picture
    91 on at

    I want to patch it directly

  • Verified answer
    v-yutliu-msft Profile Picture
    Microsoft Employee on at

    Hi @aswin12345 ,

    Do you want to update items by buttons in gallery?

    Is the gallery's data source the sharepoint list that you want to update?

    Could you tell me the field's data type that you want to update?
    I assume that the gallery's data source is the sharepoint list that you want to update and that field is datetime type, you could use ThisItem to represent the item that you want to update.

    Try this:
    1)gallery's Items: listname

    2)insert button inside the gallery

    (click pen icon firstly, insert->button)

    3)set the button's OnSelect:

    Patch(listname,ThisItem,{timefield:Now()})

     

     525.PNG

     

     

    Best regards,

  • aswin12345 Profile Picture
    91 on at

    Thank you very much for your support @v-yutliu-msft  you are a life saver. 

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 405 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 368

#3
WarrenBelz Profile Picture

WarrenBelz 244 Most Valuable Professional

Last 30 days Overall leaderboard