How to Create Anonymous Type Array in C#
12 Mar 2014, 09:09 AM
Anonymous type is a cool feature of .Net framework. Following is the example of creating anonymous type array in C#.
var array = new[] { new {Id = 1, Name="User 1"}, new {Id = 2, Name="User 2"}, new {Id = 3, Name="User 3"} };