Workbook.Print() Method
Prints the document to the default printer.
You need a license for the DevExpress Office File API Subscription or DevExpress Universal Subscription to use this method in production code.
Namespace: DevExpress.Spreadsheet
Assembly: DevExpress.Docs.v24.1.dll
NuGet Package: DevExpress.Document.Processor
Declaration
Remarks
Use this Print
method overload to send the specified workbook to the default printer. To select another printer and change printer settings, create a PrinterSettings or DXPrinterSettings class instance and pass it to the Print
method as a parameter.
To print a specific sheet in a workbook, use the Sheet.Print method.
To define general page options, use properties of the WorksheetView object accessible from the Worksheet.ActiveView property. WorksheetView enables you to specify page orientation, margins and paper size settings.
The WorksheetPrintOptions object’s properties allow you to specify more print-specific options, which include scaling, printing gridlines, titles, row and column headings, setting page order and more.
For more information on how to specify print settings and print a workbook, refer to this example section: Printing.
Calculate Formulas Before Print Operation
The default calculation mode for a Workbook is Manual. This mode implies that the Spreadsheet does not calculate formulas before it prints a document. Call the Workbook.Calculate or Workbook.CalculateFull method to calculate all formulas in the workbook.