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 / Edit a item from a Gal...
Power Apps
Answered

Edit a item from a Gallery, problem with sort and search

(0) ShareShare
ReportReport
Posted on by

I have a gallery that reads data from a Sharepoint list named Company, if in Items I only put Company, it allows me to edit in the respective form, but when I include a statement that has sort and search like this in Item:

Sort(Search(AddColumns(Company,"City",City,"Count",Country),ScrCompaySearch.Text,"NameCompany","City","Count"),NameCompany,SortOrder.Ascending)

I can't edit the item and it even gives me an error in the editing form in item: alCompanys.Selected

How can you correct it so that it allows sort and search and can it allow editing of the selected record?

 

Tahks for the help

Categories:
I have the same question (0)
  • OdinDelToro Profile Picture
    407 on at

    Hello RobertCB,

     

    You can try using SortByColumns instead of Sort.

     

    SortByColumns(Search(AddColumns(Company,"City",City,"Count",Country),ScrCompaySearch.Text,"NameCompany","City","Count"),"NameCompany",SortOrder.Ascending)

     

    Hope this helps clarify the doubt, let me know in case you're still facing an issue within it.

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • Verified answer
    RoberthCB Profile Picture
    on at

    Thanks a lot by the help, i fund the answer in this link: Edit a item from a Gallery, problem with sort and ... - Power Platform Community (microsoft.com)

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 356 Most Valuable Professional

#2
11manish Profile Picture

11manish 225 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 211

Last 30 days Overall leaderboard