public class Users
{
private UserStatus _status;
public UserStatus Status { get {return _status;} set {_status =
value;} }
}
public Enum UserStatus
{
Unknown = 0,
Pending = 1,
Banned = 2,
Ok 3,
}
Karl
--
http://www.openmymind.net/ http://www.fuelindustries.com/
"shapper" <md*****@gmail.comwrote in message
news:11**********************@h54g2000cwb.googlegr oups.com...
Hello,
How do I make a class's property to accept only pre-defined values as
it would be an enum?
Or maybe the enum can be exposed as a property?
Thanks,
Miguel