User Control with Combobox like property

EFileTahi-A

Contributor
Joined
Aug 8, 2004
Messages
623
Location
Portugal / Barreiro
I need to customize a property for my UserControl, but I need the property to have several choices inside a combobox, like TextAlignment property, where you have already 3 options (Left, Center, Right) to choose from.

Any suggestions?

Thank you
 
Well, how do I do that? Could you show me a small example?

Code:
enum myEnum { one, two, three };

public myEnum TEST
{
    get
    {
        return myEnum;
    }
    set
    {
        myEnum.one = value;
    }
}

Needless to say the above code does not work. How do I assign a selected value to a enum and how do I read from it?

Thank you
 
Back
Top