title: Linq using variable as column name in select new statement
body: <p>I have a LINQ query and as you can see I am trying to use variables as column names.</p>
  
  <pre><code>string first = "someColumnName1";
  string sec = "someColumnName2";
  string third = "someColumnName3";
  
  var data = (from i in ctx.PlanskaKalkulacijas
              where i.PKid.Value == id
              select new { first = i.NP1, sec = i.NP2, third = i.NP3}
             ).OrderByDescending(m =&gt; m.Id)
              .ToList();
  </code></pre>
  
  <p>this code produce column names in gridview as first, sec and third but I need someColumnName1, someColumnName2, someColumnName3.</p>
  
  <p>Any help ?</p>