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 / Additional rows submit...
Power Apps
Answered

Additional rows submitting when default value of data card textbox is updated via context variable.

(0) ShareShare
ReportReport
Posted on by 59

I have an edit form with a hidden data card "Approval Status" with a text box value that changes depending on whether a user selects "Save Progress" or "Submit for Approval". This works when the user submits the form for the first time, but when the user goes to generate the form for the next step, 2 extra rows are being submitted that contain only the approval status' "Pending" and "Temp", (the 2 approval status that are swapped between depending on the button clicked on the form). Why are these extra rows being submitted?

 

Save Progress OnSelect():

UpdateContext({tempsave:1}) ; SubmitForm(SummaryFormLCG1) ; SubmitForm(PlanningFormLCG1) ; SubmitForm(FinancialsFormLCG1)

Submit for Approval OnSelect():

UpdateContext({tempsave:2}) ; SubmitForm(SummaryFormLCG1) ; SubmitForm(PlanningFormLCG1) ; SubmitForm(FinancialsFormLCG1)

 Approval Status Default:

If(tempsave = 1, "Temp", "Pending")

 

 

Categories:
I have the same question (0)
  • Verified answer
    quinncain Profile Picture
    59 on at

    I figured out that this issue was due to the submit functions. The submit functions were submitting each page as a different row. 

    New code looks like this, and appears to be working:

     

    UpdateContext({tempsave:1}) ; Patch(datasource, Defaults(datasource), SummaryFormLCG1.Updates, PlanningFormLCG1.Updates, FinancialsFormLCG1.Updates)

     

  • quinncain Profile Picture
    59 on at

    This works for when the user moves to a new gate in the project, and creates the new row correctly, but is there a way I could modify this formula to have it update the row selected in the Gallery at the beginning of the process?

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 476

#2
WarrenBelz Profile Picture

WarrenBelz 365 Most Valuable Professional

#3
Vish WR Profile Picture

Vish WR 339

Last 30 days Overall leaderboard