title: Casting to List(Of T) in VB.NET
body: <p>In C# it's possible to cast to <code>List&lt;T&gt;</code> - so if you have:</p>
  
  <pre><code>List&lt;Activity&gt; _Activities;
  List&lt;T&gt; _list;
  </code></pre>
  
  <p>The following will work:</p>
  
  <pre><code>_list = _Activities as List&lt;T&gt;;
  </code></pre>
  
  <p>but the translated line with VB.NET which is:</p>
  
  <pre><code>_list = TryCast(_Activities, List(Of T))
  </code></pre>
  
  <p>throws a compilation error. So I've had a good hunt around and experimented with LINQ to find a way round this to no avail.  Any ideas anyone?</p>
  
  <p>Thanks</p>
  
  <p>Crispin</p>