Hi everyone,
I'm quite new to using PowerApps and wanted to find out how to pass text selected from a drop down list onto other screens of the app so the user does not have to enter this manually each time. So as the image shows below, when the user selects the 'Product' from the drop down list on the first screen, it should automatically pick up this text and display on the other screens as they progress on to different sections. It's needed because each screen is linked to a different SharePoint list based on the information they are filling out about that product and so it automatically populates those fields on there. Any help on how to approach this would be appreciated!
in 2023 this doesnt work
Thanks man!
Not really a concern. PowerApps reports potential performance warnings when referencing a control on another screen because in order to determine its value, it has to render that control first. I've never experienced any hint of performance issues with that method first off, but in this particular case...that dropdown has already been rendered - there is no additional rendering needed for the value. It is now global in scope and available anywhere.
In doing this though, doesn't that cause the app to render that whole screen in the background/cause that to show up as a cross-screen dependency in the App Monitor thing?
Thanks everyone. That's really helpful, I was able to get the text passed onto the different screens from what the user selects on the initial drop down list for 'Product'. I forgot to mention there is a collections function being used to save the information the user inputs on the different screens onto the associated SharePoint list. Is there a way to make the 'Product' text that is passed on to the different screens dynamic and get it added to the SharePoint field 'Product' on each list? I tried adding the code mentioned below onto the 'Product' drop down list when you 'Get data' from the SharePoint list and it didn't work. But was able to get it passed onto the different screens as static text with the suggestions above.
Controls in PowerApps are global in scope, so they can be accessed from anywhere in your app without making redundant variables.
Simply reference your combobox on the other screens. i.e. yourCombobox.Selected.<columnNameHere>
I hope this is helpful for you.
hi @AD1 you can pass it as a variable in the navigate function or set the variable on the OnChange function of the combobox based on your particular use case.
Passing variable with navigate
Navigate(yourScreen,None,{varThisValue: yourCombobox.Selected.Value}),
add a label to yourScreen and set its Text = varThisValue
Set a global Variable
On the Combobox OnChange = Set(gblThisValue,yourCombobox.Selected.Value)
add a label to yourScreen and set its Text = gblThisValue
Both these will display the selected combobox item on the labels
Result
Hope it helps,
R
OnChange, set it to something like:
Set(varDropdown, Self.Selected.Text)
You might need to do something like Self.Selected.Result/Value, depending on your drop down.
Then you can reference varDropdown where ever you need.
WarrenBelz
146,645
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,997
Most Valuable Professional