Create my own enum for widget property

Hi community!

I would like to know if there is a way to create custom Enums for widget property to avoid using string property and check in the widget if it’s an correct input. Also it could be more user friendly.

For example, I have a widget that render a 3D scene and I have a property collection that is used to binding OpcUa variable to scene component property something like:

  • componentName = “Cube”
  • propertyName = “posX”
  • value = (binding)

I would like to create an Enum for the “propertyName”.

Hope I was clear,

Regards,
Florent

Hi … you cannot introduce new data types with the WDTC, as the data types need to be implemented in the framework itself. The main reason for this limitation is, that the data type also needs to be known in the editor, to properly offer the allowed values and ranges - this is currently not possible in a dynamic way.

CHH

2 Likes

Hi Christian,
Thanks for this answer, I will keep the string property so!