用Report的PrintingSystem.SaveDocument(Stream)輸出Stream,調用時用PrintingSystem進行加載,然后用PrintPreviewFormEx進行顯示。 PrintingSystem ps = new PrintingSystem();
// Load the document from a stream.
ps.LoadDocument(Stream);
// Create an instance of the preview dialog.
PrintPreviewFormEx preview = new PrintPreviewFormEx();
// Load the report document into it.
preview.PrintingSystem = ps;
// Show the preview dialog.
preview.ShowDialog()
登錄 慧都網發表評論