cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ShadowTech
Post Prodigy
Post Prodigy

How to search a choice field from within a text input

How can I run a search in a text input for a choice field from a SharePoint list as the data source. This is a gallery.

 

Thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @ShadowTech ,

Note the below is not Delegable

Filter(
   AddColumns(
      DataSource,
      "WhateverName",
      YourChoiceField.Value
   ),
   YourTextBoxName in WhateverName
)

 

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.

View solution in original post

6 REPLIES 6
rizkyaditya
Resolver III
Resolver III

Hello @ShadowTech ,

 

You might consider this post as your answer : Search a SharePoint "Choice" column in Power Apps? 

WarrenBelz
Super User
Super User

Hi @ShadowTech ,

Note the below is not Delegable

Filter(
   AddColumns(
      DataSource,
      "WhateverName",
      YourChoiceField.Value
   ),
   YourTextBoxName in WhateverName
)

 

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.

View solution in original post

@WarrenBelz What would be your recommendation on inserting it in my current formula?

 

Sort(
    Filter(
        Search(
            'Freight-Damage',
            SearchBox.Text,
            "ClaimNumber",
            "Vendor_x0028_Origin_x0029_"
        ),
        If(
            Dropdown1.Selected.Value = "All",
            true,
            Branch.Value = Dropdown1.Selected.Value
        ),
        If(
            Dropdown2.Selected.Value = "All",
            true,
            'Claim Status'.Value = Dropdown2.Selected.Value
        )
    ),
    Created,
    Descending
)

 

Thanks in advance.

@WarrenBelz So I got it working but broke something else. I have a display form based on the "Gallery2.Selected" (This gallery) but now shows no data when a record is selected in the Gallery. Recommendations?

 

Sort(
    Filter(
        Search(
            AddColumns(
                'Freight-Damage',
                "BranchLook",
                Branch.Value
            ),
            SearchBox.Text,
            "ClaimNumber",
            "Vendor_x0028_Origin_x0029_",
            "BranchLook"
        ),
        If(
            Dropdown1.Selected.Value = "All",
            true,
            Branch.Value = Dropdown1.Selected.Value
        ),
        If(
            Dropdown2.Selected.Value = "All",
            true,
            'Claim Status'.Value = Dropdown2.Selected.Value
        )
    ),
    Created,
    Descending
)

 

Thanks in advance.

@WarrenBelz Figured it out. You now have to have the forms perform a lookup of the ID.

Hi @ShadowTech ,

I would be inclined to go this way

Sort(
   Search(
      Filter(
         'Freight-Damage',    
          (
              Dropdown1.Selected.Value = "All" || 
              Branch.Value = Dropdown1.Selected.Value
          ),
          (
             Dropdown2.Selected.Value = "All" ||
             'Claim Status'.Value = Dropdown2.Selected.Value
          )
      ),
      SearchBox.Text,
      "ClaimNumber",
      "Vendor_x0028_Origin_x0029_"
   ),
   Created,
   Descending
)

 

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.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,126)