Hey everyone,
I have a gallery with 7 fields in it. I want to be able to filter it by the 7 fields. One of the fields is a dropdown, and the others are all text inputs. I will be adding an 8th field soon(it will be a checkbox).
Also, I want it to be that when the fields are blank, it still filters the gallery but by a wildcard. That wildcard will mean "anything". My first thought was using an If statement.
Ex: If('Input-TypeOfChange.Text' in Title, StartsWith(Title, 'Input-TypeOfChange.Text') . . . The ellipses at the end is because I didn't finish it. (I know this formula is all wrong, but just bear with me)
My question: How can I create a way to filter my gallery in the easiest, and most simplest, way possible.
Thanks guys.
Somewhat unrelated question:
When I tried to implement this method(very cool and compact), I did not use the StartsWith( ) function for the combobox value. The filter would return zero results, If I add StartsWith, it works fine. Both the combobox and gallery are using the same datasource so exact matching should work. Why does and exact match not work in the filter statement?
Okay, not so much of a problem except...how are you choosing this from your filter? Are you considering a dropdown with static values and then base the filter conditions off of what is selected? What is your UI for this?
Hey again.
I have the app working as intended, but that was just stage 1. Right now we have it to where you filter an item by a specific date, but we now want to filter the dates a different way. We want to be able to filter by if "Ready To Invoice" is populated, and "Invoice/Return Date" is not. Same goes for the other date field.
Ex. "Date Requested" is populated and "Invoice/Return Date" is not, ext...
Based on previous knowledge, I feel like we will need to use IsBlank() and !IsBlank.
Thanks.
Very good. Feel free to post back if you run into problems.
I'm glad we finally got you to a solution! It's always nice to have details on how to do these things.
If this resolved your problem, please go back and find which message solved the problem and mark it as a solution so that other having the same issue can find a solution quickly.
I should be able to. I just need to update my SharePoint list and then I'll add it. Thanks for all of your help!
So you see the pattern now...are you able to add this successfully?
So that worked. Now I just need to add the "Yes/No" column to my formula.
Okay...replace the names of the dropdown and the column name in the last condition of this formula:
Filter(
'Invoice Activities - No Opportunities',
(IsBlank('Imput-TypeOfChangeFilterImput'.Text) || StartsWith(Title, 'Imput-TypeOfChangeFilterImput'.Text)) &&
(IsBlank('Imput-CustomerNameFilterImput'.Text) || StartsWith('Customer Name', 'Imput-CustomerNameFilterImput'.Text)) &&
(IsBlank('Imput-NotesFilterImput'.Text) || StartsWith(Notes, 'Imput-NotesFilterImput'.Text)) &&
(IsBlank('Date-DateRequestedFilterDatePicker'.SelectedDate) || 'Date Requested' = 'Date-DateRequestedFilterDatePicker'.SelectedDate) &&
(IsBlank('Date-ReadyToInvoiceFilterDatePicker'.SelectedDate) || 'Ready To Invoice' = 'Date-ReadyToInvoiceFilterDatePicker'.SelectedDate) &&
(IsBlank(Date-Invoice/ReturnDateFilterDatePicker'.SelectedDate) || 'Invoice/Return Date' = Date-Invoice/ReturnDateFilterDatePicker'.SelectedDate) &&
(IsBlank(SignedAgreementDropDown.Selected.Value) || SignedAgreementColumn.Value = SignedAgreementDropDown.Selected.Value)
)
It is defined as a "Choice" column. I am adding a "Yes/No" column as well for if it is completed or not.
Good deal...what kind of column is that defined as in your datasource?
MS.Ragavendar
27
mmbr1606
14
Super User 2025 Season 1
EE-04041031-0
11