cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
aurora12234
Helper I
Helper I

Create A Record Without A Form In Power Apps Using PATCH

Hi Experts, 

 

Really appreciate your help on this. Is there any way to create a record in excel or sharepoint list without using a form in powerapps with 'patch'? I did not connect my powerapps to data source like excel or sharepoint list because I needed my powerapps to be in special formats. Please let me know if you have any ideas on how this could work! 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @aurora12234 ,

Note that the xxxx refers to the valid output of the dropdown (Value/FieldName/Result) - I have a blog that may assist you here.

Patch(
   RequestCriteria,
   Defaults(RequestCriteria),
   {
      Name:TextInput1.Text
      LOB:Dropdown1_2.Selected.xxxx,
      'Commodity Type': Dropdown1_1.Selected.xxxx,
      'Part/CFG Description':TextInput1_1.Text,
      'Expected Launch/RTS':DatePicker1.SelectedDate
   }
)

 

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

8 REPLIES 8
WarrenBelz
Super User
Super User

Hi@aurora12234 ,

The Syntax is 

Patch(
   DataSource,
   Defaults(DataSource),
   {
      Field1: ControlName1Value,
      Field2: ControlName2Value
       . . . .  . . . 
   }
)

 

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.

@WarrenBelz Thanks for your answer! This is my PowerApps currently, should I include patch coding on 'submit' button (on select)? How can I connect this 'submit' button to sharepoint list or excel?

 

 

 

@aurora12234 ,

You can run it off any button/icon or Event - the DataSource is your table/list name.

@WarrenBelz Got it. Am I supposed to connect any sharepoint list table beforehand? Or it will automatically detect my table/list just by inserting data source (table/list name)? Thanks so much for your help once again

@aurora12234 ,

You need to connect to the data source beforehand.

@WarrenBelz Noted, I've connected my datasource, could you please advise if I have any errors, it's not working from my end.

 

Patch(
RequestCriteria,
Defaults(RequestCriteria),
{Name:TextInput1.Text},
{LOB:Dropdown1_2.SelectedText},
{'Commodity Type': Dropdown1_1.SelectedText},
{'Part/CFG Description':TextInput1_1.Text},
{'Expected Launch/RTS':DatePicker1.SelectedDate});

 

Navigate('Results Summary', ScreenTransition.Fade)

 

 

---------------------EOM

 

 

 

Hi @aurora12234 ,

Note that the xxxx refers to the valid output of the dropdown (Value/FieldName/Result) - I have a blog that may assist you here.

Patch(
   RequestCriteria,
   Defaults(RequestCriteria),
   {
      Name:TextInput1.Text
      LOB:Dropdown1_2.Selected.xxxx,
      'Commodity Type': Dropdown1_1.Selected.xxxx,
      'Part/CFG Description':TextInput1_1.Text,
      'Expected Launch/RTS':DatePicker1.SelectedDate
   }
)

 

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

Hi @WarrenBelz really appreciate your help on this! I've tried inserting everything but it has errors shown as below. (also attached my sharepoint list for your reference) Please advise if I've done anything wrong.

 

 

 

 

 

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

secondImage

Power Apps Community Call

Please join us on Wednesday, October 20th, at 8a PDT. Come and learn from our amazing speakers!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (1,648)