im trying to pass back from a user control a list of strings that are part of an enum, like this:
<bni:products id="bnProducts" runat="server" ProductsList="First, Second, Third" />
and in the code behid do something like this:
public enum MS
{
First = 1,
Second,
Third
};
private MS[] _ProductList;
public MS[] ProductsList
{
get
{
return _ProductList;
}
set
{
_ProductList = how_to_turn_string_to_enum_list;
}
}
my problem is I dont know how to turn that string into a list of enum, so what should be "how_to_turn_string_to_enum_list"? or do you know of a better way to use enums in user controls? I really want to be able to pass a list that neat