cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Masoud9
Level: Powered On

Fill several fields of Share Point simultaneously (Multifilling)

Hi,

 

I have an App linked to a Share Point list and I have 2 problems:

1) I would like to have a button which fills several rows of a Share Point list, but I don't know what formula I have to use. I've tried with 'Patch' but it only works (as far as I know) with only one row.

 

2) I would like to apply that formula only for some fields, the ones that have an specific value in one colum. That is, all the rows that have in the colum 1 the value "x" should have (when the button is selected) the value "y" the colum 2. The value "x" is defined by election in a previous gallery of items.

 

This is what I've tried:

If(Colum1=Gallery.Selected.Result,Patch(SPList,{Colum2:'y'},false)

 

Thank you!

 

Regards,

Masoud9

1 ACCEPTED SOLUTION

Accepted Solutions
v-siky-msft
Level 10

Re: Fill several fields of Share Point simultaneously (Multifilling)

Hi @Masoud9,

 

Do you want to assign column2 to y in these records whose column1's value is x?
 

Please try with UpdateIf function, it will replace all records that meet the condition. Set the following formula to button Onselect:

UpdateIf(SPList,Colum1=Gallery.Selected.Result,{Colum2:"y"})

For more information, please refer to https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-update-updateif

Best regards,

Sik

 

 

View solution in original post

3 REPLIES 3
Masoud9
Level: Powered On

Re: Fill several fields of Share Point simultaneously (Multifilling)

Hi again,

 

There is another way to solve my problems but I don't know if it is possible. The solution would be to fill all the items filtered by a gallery simultaneously. The gallery introduces the conditions required and then the button could fill all the gallery items in the Colum2 with the value "y"

Could someone help me with this solution?

 

What I've tried:

Patch(SharePointList;Gallery1.AllItems;{'Column2':'y'})

 

Thank you!

v-siky-msft
Level 10

Re: Fill several fields of Share Point simultaneously (Multifilling)

Hi @Masoud9,

 

Do you want to assign column2 to y in these records whose column1's value is x?
 

Please try with UpdateIf function, it will replace all records that meet the condition. Set the following formula to button Onselect:

UpdateIf(SPList,Colum1=Gallery.Selected.Result,{Colum2:"y"})

For more information, please refer to https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-update-updateif

Best regards,

Sik

 

 

View solution in original post

Masoud9
Level: Powered On

Re: Fill several fields of Share Point simultaneously (Multifilling)

Thank you @v-siky-msft that worked perfectly!

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 361 members 6,745 guests
Please welcome our newest community members: