cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Batrisyia_
Helper I
Helper I

Filter listbox from ComboBox

Dear All,

 

I have a combo box that required multiple selections from user as shown in picture below:

 

Batrisyia__0-1603111611072.png 

and this is the coding:

 

Sort(
Distinct(
Filter(
Mastercopy_1,
SYSTEM = Dropdown1.Selected.Result,
'Sub System'= Dropdown4_1.Selected.Result,
'EQUIPMENT TYPE'= Dropdown5_1.Selected.Result,
COMPONENT= Dropdown6_1.Selected.Result
),
'OPERATING TEMP (°C)'
),
Value(Result),Ascending
)

 

However, I'm trying to filter it in list box, it shows one type of material instead of all selected type of material if i used coding below:

Filter(
Mastercopy_1,
SYSTEM = Dropdown1.Selected.Result,
'Sub System' = Dropdown4_1.Selected.Result,
'EQUIPMENT TYPE' = Dropdown5_1.Selected.Result,
COMPONENT = Dropdown6_1.Selected.Result,
'OPERATING TEMP (°C)' = ComboBox4.Selected.Result)

 

Batrisyia__2-1603113629470.png

 

or it returns to error when change it to SelectedItems:

Filter(
Mastercopy_1,
SYSTEM = Dropdown1.Selected.Result,
'Sub System' = Dropdown4_1.Selected.Result,
'EQUIPMENT TYPE' = Dropdown5_1.Selected.Result,
COMPONENT = Dropdown6_1.Selected.Result,
'OPERATING TEMP (°C)' = ComboBox4.SelectedItems.Result)

 

Batrisyia__1-1603113373684.png

 

Any idea how to handle this? Thank you in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
gabibalaban
Super User II
Super User II

Hi @Batrisyia_ ,

 

Although, this is not the solution (because I guess that you work with Sharepoint list and you'll received a delegation warning due to the in usage), did you try  ?

Filter(
Mastercopy_1,
SYSTEM = Dropdown1.Selected.Result,
'Sub System' = Dropdown4_1.Selected.Result,
'EQUIPMENT TYPE' = Dropdown5_1.Selected.Result,
COMPONENT = Dropdown6_1.Selected.Result,
'OPERATING TEMP (°C)' in ComboBox4.SelectedItems.'OPERATING TEMP (°C)')

 

Selected - gives you the last combobox selected item.

SelectedItems - gives you all selected items and you want to see the 'OPERATING TEMP (°C)' column ...

View solution in original post

3 REPLIES 3
gabibalaban
Super User II
Super User II

Hi @Batrisyia_ ,

 

Although, this is not the solution (because I guess that you work with Sharepoint list and you'll received a delegation warning due to the in usage), did you try  ?

Filter(
Mastercopy_1,
SYSTEM = Dropdown1.Selected.Result,
'Sub System' = Dropdown4_1.Selected.Result,
'EQUIPMENT TYPE' = Dropdown5_1.Selected.Result,
COMPONENT = Dropdown6_1.Selected.Result,
'OPERATING TEMP (°C)' in ComboBox4.SelectedItems.'OPERATING TEMP (°C)')

 

Selected - gives you the last combobox selected item.

SelectedItems - gives you all selected items and you want to see the 'OPERATING TEMP (°C)' column ...

View solution in original post

Hi @Batrisyia_(again) ,

So to avoid delegation warning, with a little bit more resources consume, you need to use a "temporary" collection in  OnChange property of the combobox. 

ClearCollect

           (ourTemporaryCollection,

           Filter(
                    Mastercopy_1,
                                  SYSTEM = Dropdown1.Selected.Result,
                                 'Sub System' = Dropdown4_1.Selected.Result,
                                 'EQUIPMENT TYPE' = Dropdown5_1.Selected.Result,
                                COMPONENT = Dropdown6_1.Selected.Result

                   )

     )

 

and set the items property of list control to:

Filter(ourTemporaryCollection,'OPERATING TEMP (°C)' in ComboBox4.SelectedItems.'OPERATING TEMP (°C)').

in this way the filter will be executed on client side.

Hi, thank you for the suggestion and it works. Thank you very much!

 

 

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

Top Solution Authors
Top Kudoed Authors
Users online (71,695)