cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
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
mdevaney
Super User
Super User

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

Anonymous
Not applicable

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. 

 

Anonymous
Not applicable

@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
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Top Solution Authors
Users online (4,988)