protected void _dataThread_onItems(IDataGetter dataGetter) { if (this.InvokeRequired) { DTItemsHandler d = new DTItemsHandler(_dataThread_onItems); this.Invoke(d, new object[] { dataGetter }); } else { IData it; while ((it = dataGetter.GetNextItem()) != null) { if (this.ItemGet != null) { this.ItemGet(it); } this.progress(); } } }