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 / Drop down and search
Power Apps
Answered

Drop down and search

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi,

 

Help! I am getting a delegation warning error with the below code:

 

If(IsBlank(Dropdown2.SelectedText.Result),SortByColumns(Search(MyInOut,TextSearchBox1.Text,"{Name}"),"{Name}",Ascending), SortByColumns(Search(Filter(MyInOut,Tags=Dropdown2.SelectedText.Result),TextSearchBox1.Text,"{Name}"),"{Name}",Ascending))

 

Also, how do you put an option where it searches for all the names when no tags are selected.

 

Thank you in advance.

Categories:
  • Verified answer
    WarrenBelz Profile Picture
    156,545 Most Valuable Professional on at

    Hi @Anonymous ,

    Firstly, Search() is not Delegable, hence the warning. The code below does not solve the issue, just "masks" it and assists if you use the drop-down. Basically, the top filter needs to return item numbers under your Delegation limit for the Search to return the full results.

    With(
     {
     wData:
     SortByColumns(
     Filter(
     MyInOut,
     IsBlank(Dropdown2.Selected.Result)
     Tags = Dropdown2.Selected.Result
     ),
     "{Name}",
     Ascending
     )
     },
     Search(
     wData,
     TextSearchBox1.Text,
     "{Name}"
     )
    )

     

    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.

    MVP (Business Applications)   Visit my blog Practical Power Apps

     

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

#2
Mohsin Ali Profile Picture

Mohsin Ali 368

#3
WarrenBelz Profile Picture

WarrenBelz 244 Most Valuable Professional

Last 30 days Overall leaderboard