cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DELACRJO
Level: Powered On

Filtering Author using Dropdown

Hi,

 

I would appreciate some advice on how to use a dropdown control in filtering the author(Created By) field. I have a gallery which I want to filter by author using the dropdown control. I already have existing filters for my unique ID column and Title column.

 

Here is my current gallery Items formula:

If(IsBlank(SearchTitle.Text) And IsBlank(Value(SearchId.Text)), LastN('Observation Reports Test List', 20), If( !IsBlank(SearchId.Text), Filter( 'Observation Reports Test List', ID = Value(SearchId.Text)), Filter( 'Observation Reports Test List', StartsWith( Title, SearchTitle.Text))))

 

I would like to add from here the third filter which is the author by using dropdown.

 

Thank you in advance,

 

Joseph

 

3 REPLIES 3
Community Support Team
Community Support Team

Re: Filtering Author using Dropdown

Hi @DELACRJO ,

 

For the dropdown control, set below formula in Items property:

 

Distinct(ListName,Author.Email)

 

 

To filter with dropdown, using a formula like below:

Filter(ListName, Author.Email=Dropdown1.Selected.Value)

Regards,

Mona

 

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
DELACRJO
Level: Powered On

Re: Filtering Author using Dropdown

Hi Mona,

 

Thanks for the advice.

 

However, I actually tried the same formula but it didn't work. The authors are not showing in the dropdown. I'm also having delegation issues apparently, I guess I need to create a separate column to patch the user who creates the record. Would that be a viable workaround?

 

Regards,

 

Joseph

DELACRJO
Level: Powered On

Re: Filtering Author using Dropdown

Mona,

 

I was able to show the value in the dropdown. However even though the Default is set ""  it automatically selects a value.


Here is my formula in the Gallery Data Items:
If( !IsBlank(SearchId.Text), Filter( 'Observation Reports Test List', ID = Value(SearchId.Text)), If(IsBlank(SearchId.Text), Filter( 'Observation Reports Test List', StartsWith( Title, SearchTitle.Text)), Filter( 'Observation Reports Test List', Author.DisplayName = DropdownAuthor.Selected.Value)))

Capture.JPG

Can you also please explain what's the difference between Choices and Distinct function? I tried to use Choices specifying the author column in the list that I'm using but it returned all users in our organization.

 

Thanks in advance.