I have a choice column in SharePoint which allows multiple values from a separate lookup. When linking this to a PowerApp, is there a way to store all the values into a collection, so that when I create a Combobox dropdown, it only displays the items that are present in the list.
For example, the below selections are from a list of all UK cities
ID | Name |
---|---|
1 | London, Birmingham |
2 | Manchester |
3 | Manchester, Leeds, Blackpool |
4 | London, Leeds |
5 | Birmingham |
Can I have a dropdown in PowerApps that only includes the distinct values from the 5 records above?
ClearCollect(colCities,IncidentLog.Cities)
Collect(
colCities,
ForAll(IncidentLog,
{
CityNames: Cities
}
)
)
Do I need to loop through all the records? I’ve tried
Clear(colCities);ForAll(IncidentLog.Cities, Collect(colCities, [ThisRecord.Cities.Value]))