Hi @Phineas ,
I will show you but also explain it can be done a little different just for learning purposes.
Also your code for your combo is confusing because you are doing a Distinct, which works on an entire field, so you will get multiple results and something normally for the items property.
For Screen 2 are you trying to Select the Default item/Selected Items of the ComboBox based on the ID from Screen 1(Gallery 1)??. Thats different then saying populate a combo box with (selectable items) AKA the items property.
Which one do you want??? a Default selected based on Screen 1 or the Items property filled based on Screen 1??
That side for a moment lets talk about passing the data to Screen 2
1. you do not need to capture the value in a variable at all. When you do that, especially since you are making it Global, its automatically available everywhere.
Treat this value as a Context value from screen to screen.
So dont use the global variable, just do this
Navigate(Screen, Transition, { IdToSendToScreen2: Gallery1.Selected.IdColumn })
Now in screen 2, use the (I made it up) Context Variable IdToSendToScreen2, inside the items formula or the Default/DefaultselectedItems formula to auto populate the selected item.
and now you dont need to use a global variable.
If I have helped you, I would really appreciate if you please Mark my answer as Resolved/Answered, and give it a thumbs up, so it can help others
Cheers
Thank You
Michael Gernaey MCT | MCSE | MCP | Self-Contractor| Ex-Microsoft
https://gernaeysoftware.com
LinkedIn: https://www.linkedin.com/in/michaelgernaey