Ejemplo n.º 1
0
        // Allows acquiring a list of the selected items from seperate threads
        private List <string> GetSelection()
        {
            List <string> temp = new List <string>();

            if (this.InvokeRequired)
            {
                GetSelectionCallback d = new GetSelectionCallback(GetSelection);
                return((List <string>)Invoke(d, new object[] {}));
            }
            else
            {
                foreach (ListViewItem item in lvSelection.Items)
                {
                    temp.Add((string)item.Text.Clone());
                }
                return(temp);
            }
        }
Ejemplo n.º 2
0
 // Allows acquiring a list of the selected items from seperate threads
 private List<string> GetSelection()
 {
     List<string> temp = new List<string>();
     if (this.InvokeRequired)
     {
         GetSelectionCallback d = new GetSelectionCallback(GetSelection);
         return (List<string>)Invoke(d, new object[] {});
     }
     else
     {
         foreach (ListViewItem item in lvSelection.Items)
             temp.Add((string)item.Text.Clone());
         return (temp);
     }
 }