Reference selector issue

Hello everyone, I have a question. I have these two reference selectors for Area and Program. My issue is that I am trying to connect them so every time the Area reference selector is clicked on by the user, the other reference selector for Program will display the Programs for that Area. How can I do this? There are like 35 areas that I need to add and each one of them has their own programs. Also I am using a custom dropdown for the area so it can display two things(id number – name). And to add, the Program has to also have a balance(but I have solved that).They both are their own entity with attributes and are connected as a one to many association (Program → Area). Please any advice on how to solve this? I can add pictures if needed. Thanks!
3 answers

Use a microflow as datasource for the second selector and make sure the object is refreshed when the first selection has been made via the onchange action.

So first the user selects the Area, then the onchange event is triggered that refreshes the dataview object, now the second reference selector’s microflow datasource is triggered and when this contains the Area selected to restrict the list that is being retruned, you have the desired outcome.


You can achieve this by making use of the Constrained by option in the Selectable option Section of the Reference Selector. 

But in your case since you are using a custom dropdown you can follow what Erwin 't Hoen has mentioned. 
You can keep this in your memory for your future developments.

For your Reference : 


Thank you for both of your answers. To add a little more details to this, this is how I am building it. As you can see below, it is a form that is inside a entity called EAF. Now all the attributes mentioned here are from them but Program, Area, Source and Account. They are their own entity. Now I am trying to connect Area and Program since I need the programs to display from the Area chosen. The Area is built from a Custom Dropdown since it needs to display two different attributes from the Area itself. Now the Area and Program are connected to the EAF entity by associations. Erwin’s answer is good but in this form I am not allowed to use a different datasource than the associations that are given from the entities.

Also the programs so far are a list and are connected to the Area by one of the attributes which is the area number. The Area number and name are the categories for the programs and in each categories there is from 1-15 programs. And I am trying to build a figure that out. Does that make sense? is there any other way I can build this? Thank you!