web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Using a Dropdown to Fi...
Power Apps
Answered

Using a Dropdown to Filter Selections Available From Another Dropdown Within a Form

(0) ShareShare
ReportReport
Posted on by 77

Hello everyone!

 

I currently have a form which features a dropdown for a selection of building numbers and a later dropdown to select a device tag.

My hopes is to have that once a building number is selected, the device tags within this building will be the only ones that appear in the later device tag dropdown.

 

The dropdown box for the Building Number selection is DataCardValue14

The dropdown box for the Device Tag selection is DataCardValue6

 

A building example value is "B01"

Device tags for this building all start with "23-" (the rest is 3 digit numbers that vary)

 

This pattern continues so that "B03" tags start with "22-" (3 digit numbers which vary)

 

The building and beginning of tags don't correlate although I know which building has which tag beginning  

 

Could anyone please offer assistance, any help would be incredibly appreciated. Thank you very much.

 

Kind regards,

 

Joshua.

Categories:
I have the same question (0)
  • MJ84 Profile Picture
    263 on at

    Hi - try creating a collection I've made one that runs onstart of the app

     

    MJ84_0-1676630219492.png

     

    Then you can set your collection as the item property for your building drop down as below (selecting "building" as the value in properties on right hand side)

     

     

    MJ84_1-1676630323071.png

     

    Editted sorry made a mistake -Finally in the items property for the device tag drop down use the following to filter 

     

    MJ84_0-1676633287012.png

     

     

  • Holland_Joshua Profile Picture
    77 on at

    Hello MJ84.

     

    Thank you so much for your quick response and seemingly excellent solution.

    I am having an issue you could possibly help me with though?

     

    My device tag is prompting me to select the building number again, like so:

     

    Holland_Joshua_0-1676639046848.png

     

    Here are my code lines:

     

    App On Start

     

    Holland_Joshua_1-1676639077424.png

     

    Building Dropdown Items

     

    Holland_Joshua_2-1676639126935.png

     

    Device Tag Dropdown

     

    Holland_Joshua_3-1676639157737.png

     

    Thank you once again.

  • MJ84 Profile Picture
    263 on at

    Hi - in the properties for the device tag dropdown set the Value to DeviceTag

     

    Hopefully this should do it 🙂

     

     

  • Holland_Joshua Profile Picture
    77 on at

    Hello.

     

    Apologies for the delay in response. This has worked perfectly. Thank you very much.

  • MJ84 Profile Picture
    263 on at

    No problem 🙂 good luck!

  • Holland_Joshua Profile Picture
    77 on at

    Hi MJ.

     

    With this method is it possible to have multiple DeviceTags per Building. I've tried this there with comma separated values under device tag although to no avail.

     

    Holland_Joshua_0-1676988309749.png

     

    Many thanks.

     

  • MJ84 Profile Picture
    263 on at

    Hello below is the syntax you need for the onstart.

     

    MJ84_0-1676989144371.png

    If you look at the collection after doing the above you will see this.

    MJ84_1-1676989208243.png

     

    BUT I'll pre-empt the next issue! If you now go to your building drop down you will have two different B01's to select which is a bit annoying.... To get around this you can use the Distinct function in the building drop down items property -----  So change the items property in your building dropdown from ColBuilding to 

     

    MJ84_2-1676989328668.png

    This will break you device tag dropdown so you will need to change the item property of the device tag dropdown to

     

    MJ84_3-1676989420075.png

     

     

    Hope this helps

     

  • Holland_Joshua Profile Picture
    77 on at

    Hello MJ and All.

     

    Unfortunately I think the scale of my device tags is too large. I've read that PowerApps collections can only contain up to 2000 rows. There are 4000 Devices all in. These tags do exist in a choice field in my Microsoft List. Would it be possible in my form to have it so that If dropdownBuilding = example building, limit dropdownDecviceTag to example sample of tags? I'd expect to write a few if statements if this were the case but that's okay. I really appreciate the on going support. Thank you

  • MJ84 Profile Picture
    263 on at

    When you say microsoft list do you mean Sharepoint list?

  • Holland_Joshua Profile Picture
    77 on at

    Yes 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 426

#2
WarrenBelz Profile Picture

WarrenBelz 381 Most Valuable Professional

#3
Kalathiya Profile Picture

Kalathiya 315 Super User 2026 Season 1

Last 30 days Overall leaderboard