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 / Patching a boolean fie...
Power Apps
Answered

Patching a boolean field in a SharePoint Onlne list when submitting a form

(0) ShareShare
ReportReport
Posted on by 24

Dear,

 

I am currently building an app to support our company in gathering data across different departments.

To do so, the app has different screens that are tied to the same Sahrepoint entry (by using a gallery to choose the entry to edit).

 

Each screen uses a gallery that is filtered like this

 

 

Filter('CHX-Kalkulationsanforderungen';'Texts done'=false)

 

 

The idea behind this is that each screen does not only submit it's content to the SharePoint item, but also toggles a boolean item in the SharePoint list so that the gallery only shows work to do.

 

To achieve this, I have read across the forums and identified the 

 

Patch()

 

 function as a possible solution. But I do get to nowhere, when I try to include it into my submission button like this

 

SubmitForm(Form3);; Patch('CHX-Kalkulationsanforderungen';LastSubmit(Form3);{'Texte fertig': true});; ResetForm(Form3)

 

I am told that LastSubmit is an unknown or not supported function.

 

Can anyone give me some ideas on how to handle this?

 

Thank you for your support,

best regards

 

Philip

Categories:
  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @pdeubner ,

    Try on the OnSuccess of Form3 (just submit the form only in your code)

    Patch(
     'CHX-Kalkulationsanforderungen';
     {ID: Self.LastSubmit.ID};
     {'Texte fertig': true}
    );; 
    ResetForm(Form3)

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

  • pdeubner Profile Picture
    24 on at

    Dear @WarrenBelz ,

     

    thank you for your swift support. I tried to do as you suggested. 

    I changed the "OnSelect" value of the submission button of the form to

     

    SubmitForm(Form3)

    and the OnSuccess of the form to

     

    Navigate(End_Success;ScreenTransition.Fade);; Patch(
     'CHX-Kalkulationsanforderungen';
     {ID: Self.LastSubmit.ID};
     {'Texte fertig': true}
    );;
    ResetForm(Form3)

    Unfortunately I have a new entry in the corresponding list and not an updated item.

    What have I done wrong?

     

    Thank you for your support,

    regards

     

    Philip

  • Verified answer
    WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    @pdeubner ,

    Please put the Patch first, otherwise Self() will not refer to the Form.

    Patch(
     'CHX-Kalkulationsanforderungen';
     {ID: Self.LastSubmit.ID};
     {'Texte fertig': true}
    );;
    ResetForm(Form3);;
    Navigate(
     End_Success;
     ScreenTransition.Fade
    );; 

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

     

  • pdeubner Profile Picture
    24 on at

    Dear @WarrenBelz ,

    you are right - thank you for supporting me with this solution.

    Best regards

    Philip

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

#2
WarrenBelz Profile Picture

WarrenBelz 191 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 167

Last 30 days Overall leaderboard