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 / how to .. pending.. ap...
Power Apps
Unanswered

how to .. pending.. approved.. send.. sort.. button?? how to in the gallery.. thx

(0) ShareShare
ReportReport
Posted on by 1,994

hi

 

Can I know how to set the buttons onto to sort by it's status selected and the gallery to display all item by on the latest not selected or is all?? thx

 

 

bbsin_0-1623749185557.png

 

 

My gallery item is Filter(list', 'Created By'.Email=User().Email)

it should only display the user who lock in to see their own records .  Thanks.

 

 

bbsin_1-1623749323187.png

 

 

Categories:
  • zmansuri Profile Picture
    6,048 Super User 2024 Season 1 on at

    Gallery code:

    SortByColums(Filter(list', 'Created By'.Email=User().Email),varSort,
    If(
    SortDescending1,
    Descending,
    Ascending
    )

    )

    On your button's OnClick Event:

    UpdateContext({varSort :"ColumName"});
    UpdateContext({SortDescending1:!SortDescending1});

     

    That way if it's in ascending it will be set to descending and vice versa.  

  • bbsin Profile Picture
    1,994 on at

    Hi @zmansuri 

     

    Thanks , but did I missed something??? 

    bbsin_0-1623750892334.png

     

  • zmansuri Profile Picture
    6,048 Super User 2024 Season 1 on at

    You have to set values for varSort and SortDescending1 through OnClik on buttons. and if they are choice or any complex type field you can not sort it directly, You have to use AddColumns. in the gallery code.

  • bbsin Profile Picture
    1,994 on at

    @zmansuri 

     

    Not too sure .. I just want to sort by ID.  will it work??

     

  • zmansuri Profile Picture
    6,048 Super User 2024 Season 1 on at

    SortByColums(Filter(list', 'Created By'.Email=User().Email),ID,Ascending)

  • bbsin Profile Picture
    1,994 on at

    @zmansuri 

     

    Thanks but it's not working

  • bbsin Profile Picture
    1,994 on at

    @zmansuri 

     

    Did I miss something??

    bbsin_0-1623807910280.png

     

    bbsin_1-1623807974573.png

     

    The status column choice are

    bbsin_2-1623808025853.png

     

     

    Thanks

     

     

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 354 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 320

#3
Mohsin Ali Profile Picture

Mohsin Ali 246

Last 30 days Overall leaderboard