cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Kudo Kingpin
Kudo Kingpin

"Submitting" all the records in a Gallery Control back to the datasource

I have a super simple SharePoint List acting as a 'shopping list' as a sample to prove out some ideas.

 

I have it set to display the item name and if it has been purchased as shown below.

 

What I am trying to do now is have a button that takes all the records showing here and submit them back to the SharePoint list with the new values for the 'Purchased' field.

 

All the ways I know to do this tend to be for single records only and the samples of 'ForAll' seemed not to pertain and I couldnt make that work.

 

Any ideas?

 

 

2018-02-05_12-10-51.gif

Brian Kennemer
Projectified Consulting
www.projectified.com
brian.kennemer@projectified.com
3 REPLIES 3
Highlighted
Super User
Super User

Re: "Submitting" all the records in a Gallery Control back to the datasource

@BrianKennemer

 

Is the shopping list being displayed in a gallery in the powerapp? 


Vivek Bavishi aka That API Guy
PowerApps and Flow MVP
Blog | Twitter | YouTube | Community Profile | GitHub



If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Highlighted
Kudo Kingpin
Kudo Kingpin

Re: "Submitting" all the records in a Gallery Control back to the datasource

Yes.

Brian Kennemer
Projectified Consulting
www.projectified.com
brian.kennemer@projectified.com
Highlighted
Super User
Super User

Re: "Submitting" all the records in a Gallery Control back to the datasource

@BrianKennemer

 

Try something like this

 

ForAll(Gallery.AllItems,Patch(SharepointListName,First(Filter(SharepointListName,Item=ItemlabelnameinGallery.Text)),{Purchased:ToggleName.Value}))

 Let me know if you have any questions.


Vivek Bavishi aka That API Guy
PowerApps and Flow MVP
Blog | Twitter | YouTube | Community Profile | GitHub



If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors
Top Kudoed Authors
Users online (9,846)