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 / Adding form.updates to...
Power Apps
Unanswered

Adding form.updates to patch stops patching

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello,

 

I'm still new to PowerApps and you will see in my latest posts (like this one), my app suddenly stopped working properly. After a long week of debugging, I figured out that the "form.updates" at the end of my patch function, prevents patching. I'm speechless why it has suddenly stopped working, but I also cannot figure out how can I solve this issue. Here is my patch function:

 

Set(
 LastCreatedID,
 Patch(
 'SP List',
 If(
 IsBlank(LastCreatedID),
 Defaults('SPList'),
 LookUp(
 'SPList',
 ID = LastCreatedID
 )
 ),
 {
 'Name of the Person': appuser.FullName,
 Job: JobTitle.Text,
 'Official email address': appuser.Email,
 //There are around 20 fields that are used for patching data to SP
 },
 ProfileForm.Updates,
 WorkForm.Updates,
 SkillForm.Updates,
 SummaryForm.Updates
 ).ID
 )

 

As mentioned, if I remove the 

 

ProfileForm.Updates,
WorkForm.Updates,
SkillForm.Updates,
SummaryForm.Updates
 

part from my function, it works. But, this also means I cannot patch the attachments. I have multiple questions

- Why has my app suddenly stopped working after collecting a number of users' data?

- Why do removing these items from my function work?

- How can I ensure that my app functions properly while still patching the attachments?

 

Thank you, 

Categories:
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    It appears that you are attempting to split a form into multiple forms.  

    Avoid using the Patch function to do this.  Use the SubmitForm function as otherwise you are excluding all of the functionality of your form in your app and will run into problems (as you are).

     

    To split forms, please have a look over this video on Splitting forms properly.  It will describe all you need in order to split the forms simply and also to continue to use the powerful features of the form itself.

     

    I hope this is helpful for you.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @RandyHayes 

     

    First of all, where were you a few weeks ago when I was trying to build this app? 🙂 

     

    Thank you very much! I was recommended to use the Patch function by this community, because of the "If" part in my function. If the users' records already exist in the SP list, instead of creating new ID, it edits the existing record of the user. I don't have a gallery in my app because no user should be able to see others' data, instead I'm using a separate form (SummaryForm, just like your Master Form). The summary form is set to view by default, with an edit button nearby. So, in the first 3 forms people enter data and the summary allows both showing a summary of all submitted data and edit existing info. Reminding, I'm very new to PowerApps, can you help me including SubmitForm instead of Patch while still maintaining the overall functionality? Or do I need to start all over? I really need to roll out this app this week, so I'm reluctant to start over. However, I have some required fields and right now, because Patch doesn't concern with the required fields, I change the display mode of the buttons. SubmitForm will be more useful in this case. 

     

    Also, in your video, you set up all the forms as "Edit", while in this community I was recommended to use "New". My first 3 forms in which people enter their data (namely, ProfileForm, WorkForm, SkillForm) are all set to new by default. If I continue with using SubmitForm, do I also need to change them to Edit?

     

    Many thanks in advance,

     

     

     

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

#2
Mohsin Ali Profile Picture

Mohsin Ali 356

#3
WarrenBelz Profile Picture

WarrenBelz 232 Most Valuable Professional

Last 30 days Overall leaderboard