internal void addrangetolistview(ListViewItem[] obj) { if (this.InvokeRequired) { deg_addrangetolistview t = new deg_addrangetolistview(addrangetolistview); this.Invoke(t, new object[] { obj }); } else { try { listView1.BeginInvoke((MethodInvoker) delegate { listView1.Items.AddRange(obj); }, obj); } catch (System.Exception ex) { Debug.WriteLine(ex.Message); } //obj = null; } }
internal void addrangetolistview(ListViewItem[] obj) { if (this.InvokeRequired) { deg_addrangetolistview t = new deg_addrangetolistview(addrangetolistview); this.Invoke(t, new object[] { obj }); } else { try { listView1.BeginInvoke((MethodInvoker)delegate { listView1.Items.AddRange(obj); }, obj); } catch (System.Exception ex) { Debug.WriteLine(ex.Message); } //obj = null; } }