Monday, November 2, 2009

How to convert object[] to List in one line of C#?

If you're using LINQ it's a piece of cake!

List fields = values.Select(i => i.ToString()).ToList();

No comments: