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 / if I have two forms, e...
Power Apps
Unanswered

if I have two forms, each one with half of my sharepoint lists columns

(0) ShareShare
ReportReport
Posted on by 432

how do I set up the second forms datacards to work as the first forms datacards as in, all the values go into one row in my sharepoint online list.

 

https://www.spsimply.com/home/powerapps-submit-multiple-forms-at-once

 

is this how its done? i dont have the same datacards on each form, but unique ones.  

 

i thought something like submitform(form1) and submitform(form2) should work, and all the datacards values go into the same SINGLE row item?

 

 

Categories:
  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    That would not work, that would create 2 items.

    In my opinion you have 3 options:

     

    1. Use only patch funciton (NOTE: You would need to save the Form1.LastSubmit.ID or something)

    https://docs.microsoft.com/en-us/power-platform/power-fx/reference/function-patch

     

    2. Create 2 forms and use SubmitForm(Form1) to create the item with the first fields and use Patch Function to add the other fields (NOTE: You would need to save the Form1.LastSubmit.ID or something)

     

    3. Do something liket his in a single form:

    https://www.youtube.com/watch?v=s391rMNRbmA

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,

    Gonçalo Nogueira

    Check my LinkedIn!

    My website!

     

  • dperez13 Profile Picture
    432 on at

    can you elaborate on the last submit part? i currently have a variable set to lastsubmit on a button click for form one so i can submit the form but stay on the same row and not have to have the user exit out and go back in. do i need similar logic for form/screen 2?

  • dperez13 Profile Picture
    432 on at

    where does the patch go? if i have form 1 be my main exit point:

    (submitform(form1) reset form , request hide)

    do i put the

    Patch(datasource,Defaults('LIST NAME'),form2.Updates)

    right before this code?

    or do I put it on a button on form2 itself and then navigate to form 1 and then execute the very top code 

  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    If you use patch, you need to save the ID of the last submited order in order to update the item that was created by the first form

  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    First you need to submit the first form. I twould be something like this:

     

    submitform(form1);

    Set(varLastIt;Form1.LastSubmit.ID;

    (reset form , request hide)

     

    AND AFTER THAT

     

    Patch(datasource,Patch(datasource,LookUp(datasource, ID = varLastIt),form2.Updates)

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,

    Gonçalo Nogueira

    Check my LinkedIn!

    My website!

     

  • dperez13 Profile Picture
    432 on at

    would something like this work?

    on the button that navgiates you to to form2

    have

     submitform(form1)

    If 

    ( Not (IsBlank(form1.LastSubmit)

    ),

    Set(varLastIt?, form1.LastSubmit)

    EditForm(Form1)

    Navigate(form2)

     

    then after filling in the datacards on form 2

    you hit the return button which does

     

    Patch(datasource,Patch(datasource,LookUp(datasource, ID = varLastIt),form2.Updates)

    Navigate(form1)

    and then on form1 a submit form button for form1  to save

  • dperez13 Profile Picture
    432 on at

    did you mean to nest two patches together?>

  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    I cant be more clear than this:

     

    1. Use only patch funciton (NOTE: You would need to save the Form1.LastSubmit.ID or something)

    https://docs.microsoft.com/en-us/power-platform/power-fx/reference/function-patch

     

    2. Create 2 forms and use SubmitForm(Form1) to create the item with the first fields and use Patch Function to add the other fields (NOTE: You would need to save the Form1.LastSubmit.ID or something)

     

    3. Do something liket his in a single form:

    https://www.youtube.com/watch?v=s391rMNRbmA

  • dperez13 Profile Picture
    432 on at

    whats the difference between Set(varLastIt?, form1.LastSubmit)

    and Set(varLastIt?, form1.LastSubmit.ID)

     

    and

    Patch(datasource,Patch(datasource,LookUp(datasource, ID = varLastIt),form2.Updates)

    vs

    Patch(datasource,Patch(datasource,LookUp(datasource, ID = varLastIt.ID),form2.Updates)

  • dperez13 Profile Picture
    432 on at

     what do i set for the item property of form2?

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

#2
Mohsin Ali Profile Picture

Mohsin Ali 225

#3
M Bilal Khan Profile Picture

M Bilal Khan 192

Last 30 days Overall leaderboard