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

Dynamic Driven controls based on a data source

I have a SQL table containing the following fields:


Domain ID

Domain Description

Parent Domain ID


This table has data relating to domains and subdomains.

For Example you could have a domain called Finance with ID = 1 and a sub domain called Debtors with ID = 2 and ParentDomainID = 1.


This allows Debtors to fall under Finance.

Now Debtors can have a child domain as well, for example AgingPeriods with ID = 3 and ParentDomainID = 2.


My question is on whether I can create drop downs depending on the children a domain has.

In this example there would be 3 dropdowns created. But if AgingPeriods did not exist only 2 dropdowns should be created.

I don't want to create manual drop downs everytime the data changes.


Is this possible or is there an alternative.




Level 8

Re: Dynamic Driven controls based on a data source

Very interesting...


My only thoughts are that it sounds a lot like an Org Chart Tree, so you might try creating an test app from the Org Browser template and see if there's some inspiration in there for you.


Other than that I would ask you:

1) What's the goal of this app?

2) What do you want the drop downs to do?

3) How many levels (i.e. child domains) do you need to display?


For example, you can embed a flexible height gallery inside another flexible height gallery to create a pretty neat dynamic menu, but it's only two levels deep.


For more, see Paul O'Flahtery's video on : PowerApps: Gallery / SubGallery using GroupBy and Flexible Height



Level: Powered On

Re: Dynamic Driven controls based on a data source

My first though was an org chart as well(I need to generate that dynamically though).


1. This app will allow you to move to different department's data. So Debtors has a link to another table called invoices, but Creditors has the same table called invoices. This way you know which invoices are from finance-debtors and finance-creditors. (I know this should be linked better in the tables, but unfortunately the client won't change). 


2. The dropdowns should display the main data domains. Depending on the one you select it should display the children of that domain in a next dropdown (if there are children), and another dropdown from the child if there are more.


3. It can probably have 4 levels. ex. maindomain - child1 - childofchild1 - childofchildofchild1.


I have seen that you can display HTML in powerapps. I can structure the datadomain table in to an organised JSON structure. I can then maybe display it in HTML, dynamically generated from the JSON.


This is what I have thought of so far.


I will check the video, thanks for the response!

Level 8

Re: Dynamic Driven controls based on a data source

You might consider using a single dropdown and then dynamically updating a gallery when a user selects a Debtor.


I did a mock-up that I'm attaching that gives you an idea of what you might try.




Good luck finding your solution!