Cast Object to Generic List

Lots of trial and error gave me this on SL 5 but it should also work on a regular C#. You also need to add LINQ to your using list for the last half to work.

    List<object> myAnythingList = (value as IEnumerable<object>).Cast<object>().ToList()

Enjoy!

Leave a Comment