c# - How can I convert a generic List<T> to a List? -


how can convert generic list list?

i using listcollectionview , need provide ilist not ilist<t>.

i see plenty of examples convert ilist ilist<t>, not other way.

do convert manually (new list().addrange(ilist<t>)?

as list<t> implements ilist interface, can provide list<t>. if needed, cast it:

list<int> list = new list<int>(); ilist ilist = (ilist)list; 

Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -