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

DropDown Control

How would I add multipe items to a DropDown control?  For example:

 

DropDownControl.Items = "All Items" and Filter(Table, Job = Job.Selected.Value)

 

I'd like to have static items in the DropDown as well as conditional items.  Thanks!

2 REPLIES 2
Microsoft Employee

Re: DropDown Control

You will have to create a collection with both subsets of data:

ClearCollect(MergedItems, 'All Items');Collect(MergedItems, Filter(Table, Job = Job.Selected.Value))

It is very important to note that both subsets of data must have identical schema or you will not be able to merge them.

Community Support Team
Community Support Team

Re: DropDown Control

Hi @lawsonan1986,

 

Do you want to add a static item ("All Items") within the Dropdown control?

 

I have made a test on my side, please take a try with the following formula:5.JPG

Within the screen, add two Drop down controls. The Items property of first Drop down control set to following formula:

Colors

Note: The Colors represents a SP list data source within my app.

 

The OnChange property of the first Drop down control set to following formula:

ClearCollect(Collection1,
{ProductName:"All Items"},
Filter('20180619_case7',Color=Dropdown1.Selected.Value)
)

Note: The '20180619_case7' is another SP list data source within my app. The ProductName is a Single line of text type column within my '20180619_case7' SP list, which is used as a display value within my second Drop down control. I assume that you want to display Property1 property (column) of your Table within your Drop down control, please take a try to create your collection with following formula:

ClearCollect(Collection1,
{Property1:"All Items"},
Filter(Table, Job = Job.Selected.Value)
)

 

The Items property of the Second Drop down control set to following formula:

Collection1.ProductName

On your side, it is:

Collection1.Property1

 

The OnVisible property of the Screen set to following formula:

ClearCollect(Collection1,
{ProductName:"All Items"},
Filter('20180619_case7',Color=Dropdown1.Selected.Value)
)

On your side, it is:

ClearCollect(Collection1,
{Property1:"All Items"},
Filter(Table, Job = Job.Selected.Value)
)

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.