private void btnReferenceLookup_Click(object sender, EventArgs e) { //TODO: Lookup Document DocumentLibrarySelectionForm form = new DocumentLibrarySelectionForm(_allReadySelectedDocument, DocumentType); if (DialogResult.OK == form.ShowDialog()) { Document document = form.SelectedDocument; if (document != null) { atmlPreviewPanel.Open(document); _documentReference = new DocumentReference(); _documentReference.uuid = document.uuid; _documentReference.ID = document.name; DataToControls(); } } }
private void btnReferenceLookup_Click(object sender, EventArgs e) { //TODO: Lookup Document DocumentLibrarySelectionForm form = new DocumentLibrarySelectionForm(_allReadySelectedDocument, DocumentType ); if (DialogResult.OK == form.ShowDialog()) { Document document = form.SelectedDocument; if (document != null) { atmlPreviewPanel.Open(document); _documentReference = new DocumentReference(); _documentReference.uuid = document.uuid; _documentReference.ID = document.name; DataToControls(); } } }
private void uutListControl_OnFind() { var selectedUUTs = new List<string>(); foreach (ListViewItem lvi in uutListControl.Items) { var itemRef = lvi.Tag as ItemDescriptionReference; if (itemRef != null) { var docRef = itemRef.Item as DocumentReference; if (docRef != null) { selectedUUTs.Add(docRef.uuid); } } } var form = new DocumentLibrarySelectionForm(selectedUUTs, dbDocument.DocumentType.UUT_DESCRIPTION); if (DialogResult.OK == form.ShowDialog()) { Document document = form.SelectedDocument; if (document != null) { try { UUTDescription uut = UUTDescription.Deserialize(document.Item); if (uut != null) { AddUutDocumentReference(uut); } } catch (Exception e) { LogManager.SourceError(ATMLReader.SOURCE, e); } } } }