Classes

Member variable XbpPrintDialog():printToFile Foundation

Indicates if output is re-directed to a file.

Attribute: EXPORTED
Data type: Logical (.F.)
Description

When the instance variable :enablePrintToFile is set to to .T. (true), the value of :printToFile is taken as the initial value for the checkbox in the dialog window that allows the user to request re-directing printer output to a file.

When the dialog window is closed, :printToFile contains .T. (true) only if the user opted for printing to a file and the printer driver is not capable of re-directing print output. It is then the application's responsibility to handle the user's request. This could be implemented using a XbpMetaFile object, for example. However, most printer drivers are able to re-direct print output and the value of :printToFile is usually .F. (false). In this case, the user is automatically prompted for a file name when the print job is started by calling the :startDoc() method of the XbpPrinter object returned from :display().

If the default behavior of prompting the user for a file name is not desired, the name of the file to receive the print output can be specified via the :setPrintFile() method of the XbpPrinter object. This method can also be used to detect if the printer driver will output to a file when :printToFile contains .F. (false). In this case, the method returns a value equivalent to the XBPPRN_FILE_PROMPT constant.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.