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

Re: Filtering a Gallery by Combo box

Filtering by multiple selections at a time gets a lot more complex.  Now you'll have to pull the selected offices into a local collection and do a Search (rather than a Filter) to see if a record is 'in' the collection.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
Highlighted
Helper II
Helper II

Re: Filtering a Gallery by Combo box

@mdevaney 

 

Thanks.

 

One more thing. I'm still yet to bring distinct/unique values to the combo box. It's a single-text column as originally thought.

 

Regards,

CameronTCD

Highlighted
Super User
Super User

Re: Filtering a Gallery by Combo box

@CameronTCD 

FYI, you can make more than one post the solution if you wish.  I think @Pstork1 deserves credit for at least 50% of the problem solving here Cat Happy

 

https://powerusers.microsoft.com/t5/Building-PowerApps-Formerly/Filtering-a-Gallery-by-Combo-box/m-p...

Highlighted
Super User
Super User

Re: Filtering a Gallery by Combo box

@CameronTCD 

Did you try the suggestion of @Pstork1 and myself to see what shows in the auto-complete for the ComboBox Items property?  A video or screenshot would be excellent.

Highlighted
Helper II
Helper II

Re: Filtering a Gallery by Combo box

@mdevaney 

 

Video of the items property & returned distinct values:

https://www.dropbox.com/s/x2b0przpiwoojy6/Ax8DopvF1V.mp4?dl=0

Highlighted
Super User
Super User

Re: Filtering a Gallery by Combo box

@CameronTCD 

 Actually, I was hoping you could show me what happens when you type up to this point in the function and see what the automcomplete suggests

 

Distinct('Apprentice List','Base Office'.
Highlighted
Helper II
Helper II

Re: Filtering a Gallery by Combo box

@mdevaney 

 

Ah apologies, I see. 

Attached video: https://www.dropbox.com/s/qs7dsp8tenmahju/45uhGgpTww.mp4?dl=0

 

Regards,

CameronTCD

Highlighted
Super User
Super User

Re: Filtering a Gallery by Combo box

@CameronTCD 

Wierd.  I must admit I am a little confused why its not working now.

Highlighted
Helper II
Helper II

Re: Filtering a Gallery by Combo box

No worries. 

I've just created a collection in my combo box as earlier suggested.

 

If you could help me with one last thing that would be golden!

Currently if no items are selected, the gallery returns blank. Do you know a fix to this?

 

Many thanks @mdevaney , @mdevaney  for all of your help til this point.

 

Highlighted
Super User
Super User

Re: Filtering a Gallery by Combo box

@CameronTCD 

You could do something like this.  If IsBlank does not work try IsEmpty.

 

If(
    IsBlank(ComboBox.Selected.Value),
    your_code_to_filter_combobox_here )
    

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Robotic Process Automation

Let's talk about the solution provided by Microsoft for Robotic Process Automation (RPA)

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

Top Solution Authors
Top Kudoed Authors
Users online (6,164)