System.Drawing.Printing.PrinterSettings.PrintToFile Property

Gets or sets a value indicating whether the printing output is sent to a file instead of a port.

Syntax

public bool PrintToFile { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

The PrinterSettings.PrintToFile property is used by the System.Windows.Forms.PrintDialog when the user selects the Print to file option. In such a case, the output port is set to "FILE," causing the Windows printing subsystem to prompt the user for a file name when the PrintDocument.Print method is called.

Note:

The PrinterSettings.PrintToFile property is only used by the System.Windows.Forms.PrintDialog and cannot be set programmatically. The Print to file option only appears on the System.Windows.Forms.PrintDialog when the System.Windows.Forms.PrintDialog.AllowPrintToFile property is set to true.

Requirements

Namespace: System.Drawing.Printing
Assembly: System.Drawing (in System.Drawing.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0