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 Apps
Answered

Sort gallery

(0) ShareShare
ReportReport
Posted on by 58

Hi all,

 

I have a gallery that I am already filtering like this below, to ensure that items are filtered based on logged in user.

 

Filter([datasource], 'Creator Email' = VarUser.Email)

 

That first part works fine.

 

I do however also need to sort these items and I tried this:

Filter([datasource], 'Creator Email' = VarUser.Email); Sort([datasource], Created, Descending)

 

Only thing is that it is not working.

 

Any ideas on what I am doing wrong?

 

 

 

 

Categories:
  • eka24 Profile Picture
    20,925 on at

    Try this:

    Sort(Filter([datasource], 'Creator Email' = VarUser.Email), Created, Descending)
    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Scoozi Profile Picture
    64 on at

    I wanted to offer another solution.

     

    SortByColumns(Filter(list,VarUser.Email in Col1 || VarUser.Other in Col2), "Col1", If(SortAscend,Ascending,Descending))

     

    SortAscend is a context variable that is initialized to true in the on visible screen property. you can then create a button that when clicked that toggles the context variable like "UpdateContext({SortAscend: !SortAscend})". This should do what you want as well.

  • Verified answer
    MichaelBL Profile Picture
    58 on at

    Thank you for replying..

     

    I was able to figure it out on my own!

    This worked for me:

    SortByColumns(Filter([Datasource], 'Creator Email' = VarUser.Email), "Created", Descending)

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 236 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 207 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 169

Last 30 days Overall leaderboard