cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted

Searching gallery items based on multiple Input Controls as keys.

Hi, 

I want to use combination of below keys, "Originator", "Request Type", "Account Manager", "Business Unit", "Customer", "Customer Number", "Customer Status", "Tracking Number" and "Status" to search the record in the gallery.

User can select any number of keys, based on the selections records should be returned. For e.g. If user selects Joe in Originator field, Blog in Account Manager field and Customer Number as 10001 then I should get all the records which have Originator as Joe AND Blog as Account Manager AND Customer Number as 10001.

SearchImage.png

 

Thanks for the help.

Kind Regards,

Deepansh

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Super User III
Super User III

Re: Searching gallery items based on multiple Input Controls as keys.

Hi @deepansh_saxena ,

It should be something like

Filter(
   YourListName,
   Originator = YourOriginatorControlName.Selected.xxxx &&
   'Account Manager'= YourAccountManagerControlName.Selected.xxxx &&
   'Customer Number' = YourCustomerNoControl.Text
)

xxxx above references from drop-down and combo box controls depend on the Items property of the control.

When you type YourControlName.Selected. (note second dot), valid values will come up underneath. For some guidance of what they mean: -

    • If your Items are Choices(ListName.FieldName) - a Choices or Lookup field), the reference will be YourControlName.Selected.Value
    • If they are Distinct( . . .  .), it will be YourControlName.Selected.Result
    • The other option is when they are based on a field value in a list (other than Distinct), then it will be YourControlName.Selected.FieldName (actual field 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.

 

View solution in original post

Highlighted
Super User III
Super User III

Re: Searching gallery items based on multiple Input Controls as keys.

Hi @deepansh_saxena ,

Back in my timezone now - if you want Text controls, then do this

Filter(
   YourListName,
   StartsWith(Originator,YourOriginatorControlName.Text) &&
   StartsWith('Account Manager',YourAccountManagerControlName.Text) &&
   StartsWith('Customer Number' = YourCustomerNoControl.Text)
)

You need to make sure the Default of the text search boxes is "" (empty string) so all items display from the target field until something is typed in.

 

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

5 REPLIES 5
Highlighted
Super User III
Super User III

Re: Searching gallery items based on multiple Input Controls as keys.

Hi @deepansh_saxena ,

It should be something like

Filter(
   YourListName,
   Originator = YourOriginatorControlName.Selected.xxxx &&
   'Account Manager'= YourAccountManagerControlName.Selected.xxxx &&
   'Customer Number' = YourCustomerNoControl.Text
)

xxxx above references from drop-down and combo box controls depend on the Items property of the control.

When you type YourControlName.Selected. (note second dot), valid values will come up underneath. For some guidance of what they mean: -

    • If your Items are Choices(ListName.FieldName) - a Choices or Lookup field), the reference will be YourControlName.Selected.Value
    • If they are Distinct( . . .  .), it will be YourControlName.Selected.Result
    • The other option is when they are based on a field value in a list (other than Distinct), then it will be YourControlName.Selected.FieldName (actual field 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.

 

View solution in original post

Highlighted

Re: Searching gallery items based on multiple Input Controls as keys.

Hi @WarrenBelz ,

Thank You for replying back to me. I have few controls of type free text, for e.g. Originator, Account Manager, Customer and Customer Number where user has to input text. If I use your below code then in all these fields I have to type complete data so that it could be filtered for e.g. in Originator field I have to enter "Deepansh Saxena" to filter the record, my user do not want this.

He can type First Name in Originator field, Second Name in Account Manager's field and want the record which contains this result. Is this possible?

Thank You.

Regards,

Deepansh Saxena

Highlighted

Re: Searching gallery items based on multiple Input Controls as keys.

If in my requirement I could change free text input fields to Dropdowns than this solution is perfectly working well.
New screen looks like below:

DropDowns.png



Thank You @WarrenBelz, This solution should definitely be marked as Accepted so it benefit others who could have requirement to filter records based on Dropdowns.

Kind Regards,

Deepansh Saxena

Highlighted
Super User III
Super User III

Re: Searching gallery items based on multiple Input Controls as keys.

Hi @deepansh_saxena ,

Back in my timezone now - if you want Text controls, then do this

Filter(
   YourListName,
   StartsWith(Originator,YourOriginatorControlName.Text) &&
   StartsWith('Account Manager',YourAccountManagerControlName.Text) &&
   StartsWith('Customer Number' = YourCustomerNoControl.Text)
)

You need to make sure the Default of the text search boxes is "" (empty string) so all items display from the target field until something is typed in.

 

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

Highlighted

Re: Searching gallery items based on multiple Input Controls as keys.

@WarrenBelz  Thank You so much for your help, it worked.

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors
Top Kudoed Authors
Users online (5,836)