Load enumeration from file


I was wondering if there is a mechanism for loading the enumerations literals from a text file. There are cases where the literals of a class are quite lengthy and such a mechanism would help. Or we might want to model an attribute, of a class, to get values from a list contained in a text file.

To give an example, consider an attribute referring to a country name. We either want to preload the countries’ names from a text file or alternatively link this attribute to an external entity called country_names.txt.

Any suggestions?

I’m sorry that we do not support loading enumeration literals from text file. But you can make use of our Excel data import feature to achieve. You can try create a simple Enum in our application and export it to Excel. After that follow the structure in exported Excel to feed in your data, and import it back to the project. Hope this can help.

Best regards,
Rain Wong

1 Like