@AKB2021
The formula I provided is great for dynamic needs. A lot of time your app will be updating sources and you want this reflected in your app immediately.
If you don't need the dynamic nature for your app, then you can skip the collection (always best to skip a collection unless you need the ability to create, edit or delete records in your app) and change your formula to the following and put it in the OnStart (or some other "initializing" action):
Set(glbUserList,
With({choiceUserList:
SortByColumns(
Filter(
Distinct(TotalList, AssignedToUser),
!IsBlank(Result)
),
"Result"
)},
ForAll(Sequence(CountRows(choiceUserList)+1, 0),
{Value: If(Value=0,"All", Last(FirstN(choiceUserList,Value)).Result)}
)
)
)
This will give you a variable that can then be used for your control Items property. It will be the table and static.
Bad news on collections is that you can't search for them like you can a variable. Also, a collection has more overhead than a straight variable. Variables can be anything you want, so in the above, it becomes a table that can be used anywhere you need that table.