Search code examples
c#collectionsilist

Cast an IList to a Collection


I need to cast an IList to a Collection (System.Collections.ObjectModel)

How do you go about this?


Solution

  • Collection<MyClass> coll = new Collection<MyClass>(myIList);