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

Edit Form: Filtering a Drop-down based on another drop-down field

I have an edit form where I have two drop down fields, one for distributor and one for product. I now want to filter the selection for product based on the choice made for distributor. The data for this is stored inside two columns in one Excel table, such as

 

Distributor A | Product A
Distributor A | Product B
Distributor B | Product C

 

I have tried the following formulas. Neither end up filtering anything in my product dropdown, irrespective of my choice for distributor I end up seeing all products. 

 

LookUp(ProductList;DataCardValue2.Selected.Result in ProductList.Distributor;ProductList.Model)

LookUp(ProductList;DataCardValue2.Selected.Value in ProductList.Distributor;ProductList.Model)

 

DataCardValue2 is the drop-down box for the datacard containing the distributor information

 

My desired outcome would be so that the choice of distributor dictates what is shown in the product drop-down box.

 

1 ACCEPTED SOLUTION

Accepted Solutions

@Rem 

Yes, you will be able to access that information.  First you need to unlock your datacard.  So, click on that datacard and then go to advanced and unlock it.  Then you will have access to put all of these formulas you want in there.

 

Post back if you run into problems.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

3 REPLIES 3
RandyHayes
Super User III
Super User III

@Rem 

One option you can look at is using the New "Depends On" feature.  This will give you pretty much what you are looking for.

However, if you stick with the formula...the problem is, you are doing a Lookup.  Lookup only returns one record.  You want to Filter instead.

Filter(ProductList;DataCardValue2.Selected.Value in ProductList.Distributor)

I hope this helps you some.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!
Rem
Frequent Visitor

@RandyHayes 

 

Unfortunately this did not solve the issue. Firstly, I don't have access to any field named "Depends on" for this drop-down box. Secondly, the formula did not work as intended, again, not filtering out any of the choices. I believe that this might be related to the fact that I am using the "Edit form" option and the connection options integrated from that. I know that I get "Depends on" if I just add a drop-down field freely somewhere in my app. But apparently the drop-down fields available when you use an Edit Form object are more restrictive?

@Rem 

Yes, you will be able to access that information.  First you need to unlock your datacard.  So, click on that datacard and then go to advanced and unlock it.  Then you will have access to put all of these formulas you want in there.

 

Post back if you run into problems.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

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

Power Apps Community Call

Monthly Power Apps Community Call

Did you miss the call?? Check out the Power Apps Community Call here!

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (30,117)