private List <object> GetFilesToUpload() { if (lstFilesToUpload.InvokeRequired) { var del = new GetItemsDelegate(GetFilesToUpload); return(lstFilesToUpload.Invoke(del) as List <object>); } return((from object item in lstFilesToUpload.Items select item).ToList()); }
private List <object> GetUploadedFiles() { if (lstUploadedFiles.InvokeRequired) { var del = new GetItemsDelegate(GetUploadedFiles); return(lstUploadedFiles.Invoke(del) as List <object>); } return((from object item in lstUploadedFiles.SelectedItems select item).ToList()); }