Пример #1
0
        private void ShowAccessionDataSheet()
        {
            XpsDocumentViewer viewer = new XpsDocumentViewer();

            YellowstonePathology.Document.Result.Data.AccessionOrderDataSheetData accessionOrderDataSheetData = YellowstonePathology.Business.Gateway.XmlGateway.GetAccessionOrderDataSheetData(this.m_AccessionOrder.MasterAccessionNo);
            YellowstonePathology.Document.Result.Xps.AccessionOrderDataSheet      accessionOrderDataSheet     = new Document.Result.Xps.AccessionOrderDataSheet(accessionOrderDataSheetData);
            viewer.LoadDocument(accessionOrderDataSheet.FixedDocument);
            viewer.ShowDialog();
        }
 public void ViewAccessionOrderPage_Loaded(object sender, RoutedEventArgs e)
 {
     YellowstonePathology.Document.Result.Data.AccessionOrderDataSheetData accessionOrderDataSheetData = YellowstonePathology.Business.Gateway.XmlGateway.GetAccessionOrderDataSheetData(this.m_AccessionOrder.MasterAccessionNo);
     YellowstonePathology.Document.Result.Xps.AccessionOrderDataSheet      accessionOrderDataSheet     = new Document.Result.Xps.AccessionOrderDataSheet(accessionOrderDataSheetData);
     this.DocumentViewer.Document = accessionOrderDataSheet.FixedDocument;
 }
 public void ViewAccessionOrderPage_Loaded(object sender, RoutedEventArgs e)
 {
     YellowstonePathology.Document.Result.Data.AccessionOrderDataSheetData accessionOrderDataSheetData = YellowstonePathology.Business.Gateway.XmlGateway.GetAccessionOrderDataSheetData(this.m_AccessionOrder.MasterAccessionNo);
     YellowstonePathology.Document.Result.Xps.AccessionOrderDataSheet accessionOrderDataSheet = new Document.Result.Xps.AccessionOrderDataSheet(accessionOrderDataSheetData);
     this.DocumentViewer.Document = accessionOrderDataSheet.FixedDocument;
 }
Пример #4
0
        private void ButtonPrintDataSheet_Click(object sender, RoutedEventArgs e)
        {
            if (this.m_AccessionOrder.PanelSetOrderCollection.Count > 0)
            {
                Business.Persistence.DocumentGateway.Instance.Save();
                YellowstonePathology.Document.Result.Data.AccessionOrderDataSheetData accessionOrderDataSheetData = YellowstonePathology.Business.Gateway.XmlGateway.GetAccessionOrderDataSheetData(this.m_AccessionOrder.MasterAccessionNo);
                YellowstonePathology.Document.Result.Xps.AccessionOrderDataSheet      accessionOrderDataSheet     = new Document.Result.Xps.AccessionOrderDataSheet(accessionOrderDataSheetData);
                System.Printing.PrintQueue printQueue = new System.Printing.LocalPrintServer().DefaultPrintQueue;

                System.Windows.Controls.PrintDialog printDialog = new System.Windows.Controls.PrintDialog();
                printDialog.PrintTicket.PageOrientation = System.Printing.PageOrientation.Portrait;
                printDialog.PrintQueue = printQueue;
                printDialog.PrintDocument(accessionOrderDataSheet.FixedDocument.DocumentPaginator, "AccessionDataSheet");
            }
            else
            {
                MessageBox.Show("You must order something before the data sheet can be printed out.");
            }
        }
        private void ButtonPrintDataSheet_Click(object sender, RoutedEventArgs e)
        {
            if (this.m_AccessionOrder.PanelSetOrderCollection.Count > 0)
            {
                Business.Persistence.DocumentGateway.Instance.Save();
                YellowstonePathology.Document.Result.Data.AccessionOrderDataSheetData accessionOrderDataSheetData = YellowstonePathology.Business.Gateway.XmlGateway.GetAccessionOrderDataSheetData(this.m_AccessionOrder.MasterAccessionNo);
                YellowstonePathology.Document.Result.Xps.AccessionOrderDataSheet accessionOrderDataSheet = new Document.Result.Xps.AccessionOrderDataSheet(accessionOrderDataSheetData);
                System.Printing.PrintQueue printQueue = new System.Printing.LocalPrintServer().DefaultPrintQueue;

                System.Windows.Controls.PrintDialog printDialog = new System.Windows.Controls.PrintDialog();
                printDialog.PrintTicket.PageOrientation = System.Printing.PageOrientation.Portrait;
                printDialog.PrintQueue = printQueue;
                printDialog.PrintDocument(accessionOrderDataSheet.FixedDocument.DocumentPaginator, "AccessionDataSheet");
            }
            else
            {
                MessageBox.Show("You must order something before the data sheet can be printed out.");
            }
        }