Anonymous Types In LINQ

One really cool thing with C# .NET LINQ is the ability to take a query and output the data to an anonymous types. This work with either type of query be it comprehension or method syntax. The one drawback is that you can’t access this directly because it inherits directly from object. You would need to cast it as new defined type (class) to do this. You will see me doing this different ways thru the upcoming examples. How you choose to do it is based on your own personal preferences.

Continue reading