by Jan Blomquist
4. February 2009 05:00
Many users of ASP.NET has over the years created various helper classes and utilities to simplify traversing the ASP.NET Control structure. Samples include the Generic FindControl<T> function which I've seen countless implementations of.
Well, we all know that re-inventing the wheel is unwise if you want to leverage high productivity. Fortunately with the arrival of C# 3.0 we've got this little thing called LINQ which is basically just a collection of related inventions like Extension Methods, Lambdas, Anonymous Types, Object Initializers, etc. It turns out that LINQ enables us to apply some powerful querying on top of ASP.NET and in many cases with simple one liners. Using Linq directly makes code alot easier to read. Here's an example of how using Linq to validate if a Question is answered correctly just to show the power of the syntax.
More...