How to use depended EnumLists in the same Form without using Ref

If you add a new entry in EnumList1, you can select it also in EnumList2 and visa versa.
It’s also sorted alphabetically.
For that you don’t need any Ref Table.

Expression in Suggested Values in EnumList1:

SORT(
LIST(
	"A",
	"B",
	"C"
	)
  +SPLIT(EnumList[EnumList1],",")
  +SPLIT(EnumList[EnumList2],",")
  +SPLIT([EnumList2],",")
  -LIST("")
)

And in EnumList2:

SORT(
LIST(
	"A",
	"B",
	"C"
	)
  +SPLIT(EnumList[EnumList1],",")
  +SPLIT(EnumList[EnumList2],",")
  +SPLIT([EnumList1],",")
  -LIST("")
)

Check out the sample App “EnumList” in my Portfolio:
https://www.appsheet.com/portfolio/549987

4 3 1,285
3 REPLIES 3

Punch
Participant I

Neat! Would you like to expand upon possible use cases as well?

(As your reply is indexed and then hit upon a typical search in this community when you search more by expected behaviour than formal functions/expressions?)

We use it for an inspection App:
One heating system has to be checked 4 times a year.
You select the Month for each check and what has to be checked.
The “What has to be checked” is an EnumList mentioned above.

dan_R
Participant III

This might be what I have been looking for.
I have 6 enumlists on my form. They all have the same data. They are activities that can be selected for each stop the driver makes.
If I do the same thing for 6 lists, will it work the same?
Is there a better solution for this many? I was thinking they could pull the data from a table but I haven’t had any luck finding a solution.
Thanks!

Top Labels in this Space