private void showOnlyCameraReadySearchTextTickets(object o) { // limit camera ready files shown in list var limited_group = FilesFoundInCameraReady.Where(x => x.FileName.Contains(CameraReadySearchText)).ToList(); FilesFoundInCameraReady.Clear(); limited_group.ToList().ForEach( x => FilesFoundInCameraReady.Add(new CockleFileInCameraReady(x.FileName))); }
private void getFilesFromCameraReadyFolder() { // clear out existing files Files?.Clear(); FilesConvertedToPdf?.Clear(); FilesFoundInCameraReady?.Clear(); CameraReadyFileSelectorIsVisible = true; ModalOverlayIsVisible = true; if (null == FilesFoundInCameraReady) { FilesFoundInCameraReady = new ObservableCollection <CockleFileInCameraReady>(); } string CAMERA_READY_FOLDER = System.IO.Directory.Exists(@"L:\Camera Ready") ? @"L:\Camera Ready" : @"\\CLBDC02\Printing\Camera Ready"; var filesFoundInCameraReady = System.IO.Directory.EnumerateFiles(CAMERA_READY_FOLDER); filesFoundInCameraReady.ToList().ForEach(x => { FilesFoundInCameraReady.Add(new CockleFileInCameraReady(x)); }); }