Okay well this works and doesn't take 10-20 seconds to load.
Code:class WDFEntryList : List<WDFEntry>, System.ComponentModel.IListSource { public bool ContainsListCollection { get { return true; } } public System.Collections.IList GetList() { return this; } } class WDFFileList : List<WDFFile> { public WDFEntryList Entries = new WDFEntryList(); public void Refresh() { Entries.Clear(); foreach (WDFFile f in this) { foreach (WDFEntry e in f.Entries) { Entries.Add(e); } } } }Code:UsageList.DataSource = null; Files.Refresh(); UsageList.DataSource = Files.Entries;




Reply With Quote