# Is it possible to define ECProperty as enum type?

Hi,

is it possible (and if yes, is there an example available) to define ECProperty as enum type, so the only predefined values will be possible to choose from MicroStation GUI when the property is edited? I guess a relationship to some class with array of values can be the solution, but was not able to create such schema so far.

With regards,

Jan

Parents
• is it possible (and if yes, is there an example available) to define ECProperty as enum type

Hidden in MicroStation CONNECT Update 7 are Pick Lists.  In that Update I don't think that they were intended to be publicly visible.  Perhaps we'll see more in Update 8.

See Krister Surell's post about `Picklists` and C#.  He obviously spotted something that I missed!

AFAIK all ECProperties (and hence Item Types) are ultimately XML data.  There are structures such as ValueMaps (see the delivered EC Schemas) that could be interpreted as a C#/C++ `enum`,  but there's no way that I know of to convert a ValueMap to an `enum` at run-time.

Regards, Jon Summers
LA Solutions

See Krister Surell's post about `Picklists` and C#.  He obviously spotted something that I missed!
AFAIK all ECProperties (and hence Item Types) are ultimately XML data.  There are structures such as ValueMaps (see the delivered EC Schemas) that could be interpreted as a C#/C++ `enum`,  but there's no way that I know of to convert a ValueMap to an `enum` at run-time.