I know I can create a List<T> from IEnumerable<T> by doing myEnumerableCollection.ToList(), but how could I implement the same thing for an ObservableCollection<T> ?
I know I can create a List<T> from IEnumerable<T> by doing myEnumerableCollection.ToList() , but
Share
What you’re looking for is extension methods.
You can extend the
IEnumerable<T>type like this:Don’t forget to add the using directive in classes you want to use this in (i.e:
using myNameSpace;)