.NET Tip: Converting Strings to Enum Values
Learn how to take a string and convert it into an enumeration value.
Learn how to take a string and convert it into an enumeration value.
The documentation on Microsoft's flags enumerations is rather sketchy at best, but offers a more ideal solution for a great many problems. The problem is, with such little documentation it can be very time consuming to figure out how to use them correctly. Here is a small walkthrough explaining a relatively simple means of interacting with them through use of the bitwise OR operator.
How to convert a string value to a given enumeration type using System.Reflection.