cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
gennarodp
Post Patron
Post Patron

Create new records in a sharepoint list with a button

Hello,

i have an edit form that is related from a gallery (source sharepoint list)

 

when i select a single records of gallery, the app open a new screen with a editform linked with detailed datas of selected record.

 

i would like in this editform to create records in a new sharepoint list, from detailed data of editform, with a button.

i have already connect the sharepoint list.

 

Could i use collect function for this ?

 

thank you all

1 ACCEPTED SOLUTION

Accepted Solutions
eka24
Super User III
Super User III

You can use Patch Function.

Onselect of a Button:

Patch(Datasource, Defaults(Datasource), {Column1: DatacardValue1,

Column2: DatacardValue2,

Column3: DatacardValue1 })

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

8 REPLIES 8
eka24
Super User III
Super User III

You can use Patch Function.

Onselect of a Button:

Patch(Datasource, Defaults(Datasource), {Column1: DatacardValue1,

Column2: DatacardValue2,

Column3: DatacardValue1 })

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

@eka24  do you know also how use in the body of email connector of power apps, what is the comand to wrap text (comand send in email to wrap text) ?

 

Thank you

eka24
Super User III
Super User III

Is the patch resolved?

Can you put the question in another post since it not related.

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

yes thank you very much

gennarodp
Post Patron
Post Patron

@eka24, formula doesnt go in error, but in sharepoint list there arent' records 😞

eka24
Super User III
Super User III

Can you show the formula?

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

IfError(Patch('Richieste di Manutenzione';Defaults('Richieste di Manutenzione');{'Centro di Lavoro':DataCardValue4;'Data/ora apertura guasto':Now();Codifica:DataCardValue5;'Unità Principali':DataCardValue6;'Descrizione del guasto dal Campo':DataCardValue7;Title:DataCardValue10});Notify("Qualcosa è andato storto";NotificationType.Error);Notify("Intervento sottomesso alla Manutenzione correttamente";NotificationType.Success))
eka24
Super User III
Super User III

For all Textboxes / Datacardvalues, add .Text

Example: DataCardValue4.Text
               DataCardValue10.Text

 

If it a Dropdown: DataCardValue4.Selected.Value

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

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.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (1,482)