cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Button modify field item checked

Hello;

 

When i click on the button i would that if an item is checked modify this field

 

My BrowseGallery is a List SharePoint an my field is Status_Request

 

I test but without succes :

 

ForAll(BrowseGallery1.AllItems;If(Checkbox2.Value; BrowseGallery1.Selected.Status_Request.Value="Approuved";Notify("false")))

 

ForAll(BrowseGallery1.AllItems;UpdateIf('Home Working Test'; BrowseGallery1.AllItems.Checkbox2.Value=true; BrowseGallery1.AllItems.Status_Request.Value="Approuved");

 

Sans titre.png

Thank you for you help ! 🙂 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Power Apps
Power Apps

Re: Button modify field item checked

If you want to modify all items that have been selected (by setting their Status_Request value to Approved), then you can use this expression:

ForAll(
    Filter(BrowseGallery1.AllItems; Checkbox1.Value = true);
    Patch(deleteme20190913; { ID: ID }; { Status_Request: { Value: "Approved" }}))

The Filter will only return the items from the gallery that are checked; the ForAll function will go through each of those items and call Patch on them, using the ID of the item to identify the item in the SharePoint list, and updating only the value of the column Status_Request.

Hope this helps!

View solution in original post

3 REPLIES 3
Highlighted
Power Apps
Power Apps

Re: Button modify field item checked

If you want to modify all items that have been selected (by setting their Status_Request value to Approved), then you can use this expression:

ForAll(
    Filter(BrowseGallery1.AllItems; Checkbox1.Value = true);
    Patch(deleteme20190913; { ID: ID }; { Status_Request: { Value: "Approved" }}))

The Filter will only return the items from the gallery that are checked; the ForAll function will go through each of those items and call Patch on them, using the ID of the item to identify the item in the SharePoint list, and updating only the value of the column Status_Request.

Hope this helps!

View solution in original post

Highlighted
Frequent Visitor

Re: Button modify field item checked

thanks you for the help ! 🙂
Highlighted
Frequent Visitor

Re: Button modify field item checked

Hello,

 

After this ForAll it's possible to refrech the list ? 

 

Refrech('deleteme20190913')

 

Thank you for you help 🙂

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Robotic Process Automation

Let's talk about the solution provided by Microsoft for Robotic Process Automation (RPA)

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

Top Solution Authors
Top Kudoed Authors
Users online (10,779)