cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ajithd6368
Helper II
Helper II

Use patch function to update sharepoint List

Hi Team ,

 

I'm trying to update an existing record in List with below patch command , but gives an error  " The fuction Patch has an Invalid Argument" . 

 

Patch(AssetTransactions,Form1.Selected,{Status:Status_DataCard2.Text})

 

attaching screen shots ..

 

First , list the data on a galley(gallery2)( 123.png) and once selected a particular  record it will directed to a form(Form1)(124.png) with  record details .. manager can review the record and approve . Onselect Approve button i want to update the relevant record in list with the updates done in the Status datacard . I used above expression , but gives an error as i mentioned .

 

pls advice 

 

rgds

AD

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
PowerRanger
Resident Rockstar
Resident Rockstar

@ajithd6368 For that you don't need to use patch. Just add a button and on its OnSelect property use

SubmitForm(Form1)

This will save the changed from your form.

 

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.




​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.

View solution in original post

3 REPLIES 3
RobElliott
Super User
Super User

You don't want to patch the data card, just the value in the field. So if your data card is named Status_DataCard2 and the field in it is named dataStatus, then you patch dataStatus.Text.

 

Rob
Los Gallardos
Intranet, SharePoint and Power Platform Manager (and classic 1967 Morris Traveller driver)

PowerRanger
Resident Rockstar
Resident Rockstar

@ajithd6368 For that you don't need to use patch. Just add a button and on its OnSelect property use

SubmitForm(Form1)

This will save the changed from your form.

 

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.




​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.

Thanks PowerRanger .. it worked .. so simple 😀

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on June 15, 2022 at 8am PDT.

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Top Kudoed Authors
Users online (3,738)