cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
TobiasSQA
Frequent Visitor

Filter that shows all items

Hello.

 

I have an app where I'm filtering items based on a sharepoint choice column, this filtering is happening based on the selection of a dropdown, the dropdown takes items from the sharepoint list.

 

Any ideas on how I would add a selection to that dropdown that would then disable the filtering and just show all items.

 

Items are being shown on a map (Geospatial Feature), but in theory it should be the same as a gallery

Thanks in Advance 
TQA

1 ACCEPTED SOLUTION

Accepted Solutions
v-yujincui-msft
Community Support
Community Support

Hi @TobiasSQA ,

 

Do you want to show all items while using a Drop Down Control?
Maybe you might consider creating a collection and setting the Items property of the Drop Down Control to it.

 

I have made a test for your reference.

1. Here is my data source.

vyujincuimsft_0-1649834049902.png

2. Select the Screen and apply the following formula on its OnVisible property as:

ClearCollect(collectionWithBlank,{Value:""}); Collect(collectionWithBlank,Choices(tmplist.status))

3. Select the Drop Down Control and set its items property to collectionWithBlank.

4. Select the Gallery and apply the following formula on its Items property as:

If(IsBlank(Dropdown2.Selected.Value),tmplist,Filter(tmplist,Dropdown2.Selected.Value=status.Value))

Result Screenshots:

vyujincuimsft_1-1649834627162.pngvyujincuimsft_2-1649834658582.png

 

Best Regards,
Charlie Choi

View solution in original post

2 REPLIES 2
v-yujincui-msft
Community Support
Community Support

Hi @TobiasSQA ,

 

Do you want to show all items while using a Drop Down Control?
Maybe you might consider creating a collection and setting the Items property of the Drop Down Control to it.

 

I have made a test for your reference.

1. Here is my data source.

vyujincuimsft_0-1649834049902.png

2. Select the Screen and apply the following formula on its OnVisible property as:

ClearCollect(collectionWithBlank,{Value:""}); Collect(collectionWithBlank,Choices(tmplist.status))

3. Select the Drop Down Control and set its items property to collectionWithBlank.

4. Select the Gallery and apply the following formula on its Items property as:

If(IsBlank(Dropdown2.Selected.Value),tmplist,Filter(tmplist,Dropdown2.Selected.Value=status.Value))

Result Screenshots:

vyujincuimsft_1-1649834627162.pngvyujincuimsft_2-1649834658582.png

 

Best Regards,
Charlie Choi

Hello Charlie 

 

Sorry for the late response, your solution worked flawlessly, thank you so much 🙏

 

Best Regards,
Tobias Andersen

Helpful resources

Announcements
Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Super User 2 - 2022 Congratulations

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Government Carousel

New forum: GCC, GCCH, DoD - Federal App Makers (FAM)

In response to the unique and evolving requirements of the United States public sector, Microsoft has created Power Apps US Government.

Users online (1,895)