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

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
Super User
Super User

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

@MadeleineDT 

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."

MadeleineDT Helper I
Helper I

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. 

 

MadeleineDT Helper I
Helper I

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
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

‘Better Together’ T-Shirt Contest – Winner Announced!

‘Better Together’ T-Shirt Contest – Winner Announced!

And the winner is...

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Power Platform 2020 release wave 1 plan

Power Platform 2020 release wave 1 plan

Features releasing from April 2020 through September 2020

Top Solution Authors
Top Kudoed Authors
Users online (5,831)