cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Auto populate 2nd screen form from 1st screen data

Hi, I have 3 SharePoint lists. Each list should be populated one after each other. But each list item have the BU and Title in common. 

I created a form starting with the first list and then added new screen that points to the new list. But I would like the BU and Title that was saved on the first screen and first list to populate the BU and Title on the second screen and of course the second list. And the same will apply to the 3rd list and screen. 

I added a button to the first screen with this command 

SubmitForm(SharePointForm1); Navigate(Criticality, ScreenTransition.Fade)

 

Am I on the right approach? Should I rather be doing an app than a form? Or should I just merge all the lists into one and have all 3 forms populate the same list?

List one checks applicability, if applicable you will then complete list 2 which is criticality and then list 3 which is security.

 

Really appreciate your feedback

 

 

3 REPLIES 3
Highlighted
Super User III
Super User III

Re: Auto populate 2nd screen form from 1st screen data

@Anonymous 

The LASTSUBMIT property of a form stores data from the last successfully submitted record.  It will be helpful here.

 

Put this code in the OnSuccess property of Form 1.

 

Set(myLastRecord, Form1.LastSubmit)

 

Then put this code in the Default property of the Title field in Form2.

 

myLastRecord.Title

 

And this code in the Default property of the BU field in Form2.

 

myLastRecord.BU

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Highlighted
Anonymous
Not applicable

Re: Auto populate 2nd screen form from 1st screen data

Hi @mdevaney 

 

It seemed to have worked with the title but not the BU. So still need to do some investigation. I checked field names, ect and they look right. Can't seem to find a reason why its not working. 

 

Can I add some complexity though? 

 

In my SharePoint list I have a derived field. It is made up of the list ID and the title given in the first screen. My customer decided that it is that derived title field that should be used in the subsequent forms. I checked and the derived field works in the list. 

I did not add the derived field on screen1. Will I have to in order to use it in the subsequent screens?

 

Thank you so much for helping. 

 

Highlighted
Anonymous
Not applicable

Re: Auto populate 2nd screen form from 1st screen data

@mdevaney 

 

I did have success with my derived field by adding it to the first screen. However I'm still battling with the Business Unit field. Could it be because the BU field is a dropdown field?

 

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (2,830)