cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
infant_Dev
Level: Powered On

Sort by ID

Team,

 

This is my first post in Power Apps, And just created SharePoint list and published app.

I see the list items are not getting sort based on list ID in App,Can any one please help me how can I make it.

 

Thanks & Regards,

Infanst_PowerAppDeveloper

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Sort by ID

Hi @infant_Dev ,

Do you want to sort your Gallery Items based on ID column of your SP list?

 

I have made a test on my side, please consider modify the formula within the Items property of the Gallery to following:

SortByColumns(
Filter('YourSPList', StartsWith(Title, TextSearchBox1.Text)),
"ID", /* <-- Modify formula here */
If(SortDescending1, Descending, Ascending)
)

8.JPG

 

Please take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
lucia
Level 8

Re: Sort by ID

Hey,

 

just set your gallery's items field (in advanced option) to:

 

Sort(datasource/sharepoint list, ID, descending/ascending)

 

Hope this helps.

Dual Super User
Dual Super User

Re: Sort by ID

Hi @infant_Dev 

 

You can use Sort function if you wish to sort the items based on ID.
 
Sort(SharePointListName, ID, Ascending)
 
Third parameter represents the order of Sorting, this can be Ascending or Descending.
 
Also, if you want to expand this to multiple columns you can use SortByColumns function as:
 
SortByColumns(SharePointListName, ID, Ascending,Name,Descending)
 

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Community Support Team
Community Support Team

Re: Sort by ID

Hi @infant_Dev ,

Do you want to sort your Gallery Items based on ID column of your SP list?

 

I have made a test on my side, please consider modify the formula within the Items property of the Gallery to following:

SortByColumns(
Filter('YourSPList', StartsWith(Title, TextSearchBox1.Text)),
"ID", /* <-- Modify formula here */
If(SortDescending1, Descending, Ascending)
)

8.JPG

 

Please take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

infant_Dev
Level: Powered On

Re: Sort by ID

Tq for your gentle response

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (5,508)