title: Convert List<T> to List<string> generically
body: <p>I have a situation where I am reflecting on a set of properties at runtime. When I get the actual property value out, it's simply of type object but I do a check to confirm that it is a generic List. In my scenario these generic Lists will always contain primitive values of some kind (ints, strings, longs, etc). Is there a simple way to convert whatever type of List it is to a list of strings? Like this:</p>
  
  <pre><code>object obj = pi.GetValue(item, null);
  Type type = obj.GetType();
  if (type.IsGenericType &amp;&amp; type.GetGenericTypeDefinition() == typeof(List&lt;&gt;)) {
      List&lt;string&gt; lstStrings = ???;
  }
  </code></pre>
  
  <p>Or do I have to have a big switch statement and cast to the appropriate runtime List type first then convert that to List?</p>
  
  <p>thanks</p>