web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / OnSelect - SubmitForm,...
Power Apps
Unanswered

OnSelect - SubmitForm, Patch and Navigate

(0) ShareShare
ReportReport
Posted on by 51

Hello all,

 

I am new to PowerApps and need help with the Patch function.

 

To update a gallery I am using EditForm1, this navigates back to the browse screen after updating the SharePoint list. So the code below works.

 

SubmitForm(EditForm1);

Navigate(BrowseScreen1)

 

The problem starts when I add a patch function to update a different SharePoint list (VendorToWaferDetails) in the same OnSelect code. I use the code below.

 

SubmitForm(EditForm1);
Patch('VendorToWaferDetails', Defaults('VendorToWaferDetails'),
{ 
 	'Batch ID':DataCardValue18.Text,	
	'Wafer ID':DataCardValue10.Text,	
	'Vendor Ingot No':DataCardValue21.Value,	
	'Vendor Box ID':DataCardValue19.Text,	
	'Vendor Box Slot':DataCardValue20.Value,
 	'Date of batch up':Now(),	
	'Assignment':DataCardValue17.SelectedText.Value,	
	'Operator':DataCardValue2.SelectedText.Value,
}); 
Navigate(BrowseScreen1)

 If I try the patch function alone it still fails to compile.

rob468_2-1690550331656.png

 

I have connected to both SharePoint lists and altered my code several times but cannot seem to solve the issue. 

 

Any ideas?

 

Your help is much appreciated.

 

Thanks,

 

Rob

Categories:
I have the same question (0)
  • the_dude Profile Picture
    361 Super User 2024 Season 1 on at

    Hi Rob,

     

    I've tested it out with a (smaller) test situation on my tenant.

    And from what I can tell I think the problem is the very last , (comma) at the end of:

    'Operator':DataCardValue2.SelectedText.Value,

     

    The comma is used to indicate ''the next property is coming after this'' though this is the last property.

     

    Could you give it a try and let me know? if this fixed it please mark it as solved if not we'll puzzle further together! 

  • timl Profile Picture
    36,415 Super User 2025 Season 2 on at

    Hi @rob468 

    In addition to what @the_dude says (which is definitely a cause of the problem), I'd also check that you've added the formula in the correct place. 

    Your screenshot indicates that the location of the error lies in the Fill property.

    timl_0-1690555213829.png

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard