I have a class called "Prop". I want that class to have a property
called "DataType" where the user can select and store a datatype. How
can I store a DataType value in a class property.
how the code would work in my mind:
dim TempProp as new Prop
TempProp.DataType = String
You can use System.Type type and GetType operator for that purpose:
~
TempProp.DataType = GetType(String)
~
But if you have a limited set of types you can allow, then you may
consider using an enum as well.
Roman
> I have a class called "Prop". I want that class to have a property
> called "DataType" where the user can select and store a datatype. How
[quoted text clipped - 4 lines]
> dim TempProp as new Prop
> TempProp.DataType = String