title: Method to take in any Enum
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/79126/create-generic-method-constraining-t-to-an-enum">Create Generic method constraining T to an Enum</a>  </p>
  </blockquote>
  
  
  
  <p>is it possible to create a generic method that takes in any enum?  I'll then check the incoming type to first make sure it's an enum that was passed (or can I enforce that natrually through the method definition?) and second then if it's an enum, I will have a bunch of case statements that do stuff based on what type of enum that was passed.  So for example I can pass it CompanyColumns, PayColumns, etc. which are enums.  My method needs to be able to take any enum like this and allow me to then work with the enum in my internal case statement.</p>
  
  <p>public static DbType GetColumnDataType(I want to be able to pass in any object that's an enum) </p>