if (Enum.IsDefined(typeof(YourEnum), yourInt)) { return (YourEnum) yourInt; } OR: if (Enum.IsDefined(typeof(YourEnum), yourInt)) { return (YourEnum) Enum.ToObject(typeof(YourEnum), yourInt); }