Convert int to Enum using Enum.ToObject() Method
Use the Enum.ToObject() method to convert integers to enum members, as shown below.
Use the Enum.ToObject() method to convert integers to enum members, as shown below.