web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Sort Variable in Power...
Power Apps
Answered

Sort Variable in PowerApp List

(0) ShareShare
ReportReport
Posted on by 224

This is my Variable:

ClearCollect(ProviderCollection,Filter('Provider Inclusion By State','State (State0)' = NameList1_8.Selected.Value).Provider);ClearCollect(DistinctSkillingCollection,
Filter('Provider_Resource_Guide','Name (Title)' in ProviderCollection.Provider &&'AR Start' <= Value(TextInput1.Text) &&'AR End' >= Value(TextInput1.Text)));

UpdateContext({FilteredSkillingCollection: Distinct(DistinctSkillingCollection,Skilling)});


Not sure how to sort this according to 'Skilling'. I'm just plugging the variable, FilteredSkillingCollection, into my list but no sorting occurs no matter if I try to build the sort in the variable or the list. Please and thank you!

Categories:
I have the same question (0)
  • fnanfne Profile Picture
    260 on at

    Not too sure what you're asking, sorry if I misunderstood.

     

    If you have a collection, display that collection in a Gallery, and then do the sorting operation there. I have similar code to the following on my Galleries...

     

    In the Gallery's Items property, add the following code.

     

    Sort(Filter(collectionName,
     date = Today(),Skilling,SortOrder.Descending)

     

    This will filter your collection based on the date, and then sort the collection based on the Skilling column.

  • Verified answer
    timl Profile Picture
    36,725 Super User 2026 Season 1 on at

    @kgiles123 

    I assume what you mean by this is that you've set the Items property of a gallery control to  FilteredSkillingCollection

    >>I'm just plugging the variable, FilteredSkillingCollection, into my list but no sorting occurs

     

    If that's the case, you can sort by the Skilling column by using this formula.

    SortByColumns(FilteredSkillingCollection,
     "Value"
    )
  • kgiles123 Profile Picture
    224 on at

    Thank you Timl!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 549 Most Valuable Professional

#2
Kalathiya Profile Picture

Kalathiya 225 Super User 2026 Season 1

#3
Haque Profile Picture

Haque 224

Last 30 days Overall leaderboard