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
Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

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

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

<
Users online (4,106)