cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
CanD
Helper III
Helper III

Smart Dropdown with Sharepoint - DD with update items

Hello Community,

 

to raise my powerapps skills i created an app, where users can book cars. I created a Sharepoint list with colums like Brand, color and licence plate. In that list i also created some cars. In the app i have a screen with 3 dropdowns.

Now to my question: I want to have 3 smart dropdowns, for example if i choose Audi at brand then in color only the colors (not all-only unique once) of the audi cars should be able to choose. Therefore it have to look at the sharepoint list which car we have. If i choose Audi-black then only the licence plates of my black Audis should be able to choose.

 

I am trying it now for too long, so i hope someone can help me.

 

Thank you really much.

 

Best regards,

CanD

1 ACCEPTED SOLUTION

Accepted Solutions
v-qiaqi-msft
Community Support
Community Support

Hi@CanD,

Do you want the three Dropdowns options to depend on each other?

Since you have all the three Text columns, I think there is no need to create collections.

Here is a workaround that you can follow.

Add three Dropdowns named "BrandDD","ColorDD","LicensePlateDD".

Set the Items property of the BrandDD as below:

Distinct(Cars,Brand)

Set the Items property of the ColorDD as below:

Filter(Cars,Brand=BrandDD.Selected.Result).Color

Set the Items property of the LicensePlateDD as below:

Filter(Cars,Brand=BrandDD.Selected.Result && Color=ColorDD.Selected.Color).LicencePlate

2020122301Gif.gif

Best Regards,

Qi

 

View solution in original post

4 REPLIES 4
v-qiaqi-msft
Community Support
Community Support

Hi@CanD,

Based on the issue that you mentioned,do you want to create cascading dropdowns?

Could you please tell me that:

  1. what is the column type of your columns, are they all Choice or Text?
  2. if the Color is Choice type ,does it allow multi select?
  3. do you use a Combo Box?

Regards,

Qi

Hi @v-qiaqi-msft ,

thanks a lot for the answer. The columns are all Text. I don't use combo box. At the moment i only have one list on sharepoint, where all my cars are in it. In the app, i created some collection for example colColor, colCar and so on. I take the informations out of the list with:  "  ClearCollect(ColColor;ColAllCars_SP.Color);;   ". It worked so far, but it shows me everytime all colors. For example. i have one red Audi. If i choose Audi in brand  it only should show me the color red in the dropdowns. If it doesn't work with Text, i could switch to Choice. 

 

Thank you very much for the help.

 

Best regards,

cd

v-qiaqi-msft
Community Support
Community Support

Hi@CanD,

Do you want the three Dropdowns options to depend on each other?

Since you have all the three Text columns, I think there is no need to create collections.

Here is a workaround that you can follow.

Add three Dropdowns named "BrandDD","ColorDD","LicensePlateDD".

Set the Items property of the BrandDD as below:

Distinct(Cars,Brand)

Set the Items property of the ColorDD as below:

Filter(Cars,Brand=BrandDD.Selected.Result).Color

Set the Items property of the LicensePlateDD as below:

Filter(Cars,Brand=BrandDD.Selected.Result && Color=ColorDD.Selected.Color).LicencePlate

2020122301Gif.gif

Best Regards,

Qi

 

View solution in original post

Hi @v-qiaqi-msft 

sorry for responsing so late. I did not have access to my accounts during christmas. I tested it and it worked more then perfect. Thank you soooo so much for your help 🙏

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

secondImage

Demo Extravaganza is Back!

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

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Did you miss the call? Check out the recording here!

Top Solution Authors
Top Kudoed Authors
Users online (18,826)