PrintText() action

Captures a snapshot of the current screen contents and saves it to a file or to the printer.

Parameters

 * file
 * Directs the snapshot to a file instead of the printer.


 * string
 * Returns the snapshot as a string, instead of directing it to the printer.


 * printer
 * Directs screen traces to the printer.


 * html
 * With file or string, saves the snapshot as HTML.


 * rtf
 * With file or string, saves the snapshot as Rich Text.


 * dialog
 * On Windows, ensures that a printer selection dialog appears, even on emulators like s3270 where it is normally suppressed.


 * nodialog
 * On Windows, prevents a printer selection dialog from appearing, even on emulators like wc3270 where it is normally would appear.


 * replace
 * With file, causes the file to be replaced if it already exists.


 * append
 * With file, causes the snapshot to be appended to the file if it already exists. This is the default behavior.


 * modi
 * Displays modified fields in italic.


 * oia
 * Includes the Operator Information Area in the output. The text mostly resembles the OIA from c3270. New in 4.1


 * secure
 * In x3270, suppresses the dialog that allows the print command to be edited.


 * caption text
 * Specifies a caption for the snapshot. Within text,  is replaced with a timestamp.

As the last keyword, specifies that what follows is the command to run.
 * command
 * filename
 * With file, the final parameter must be the name of the file to save to. If not otherwise specified, the snapshot type can be inferred from the suffix on the name.


 * print-command
 * On POSIX, the optional final parameter is the printing command. The screen snapshot will be fed as plain text to that command's standard input. The default print command is controlled by the printTextCommand resource.


 * printer
 * On Windows, the optional final parameter specifies the name of the printer to use. The default printer can be overridden by the printer.name resource.

Resources
A number of resources control the behavior of PrintText.

Examples
Capture a screen snapshot on the default printer. PrintText Capture a plain text screen snapshot in a file. PrintText(file,/tmp/snapshot.txt) Capture an HTML screen snapshot in a file. PrintText(file,/tmp/snapshot.html) Return the screen contents as text. PrintText(string) Return the screen contents as HTML. PrintText(string,html) Send a screen snapshot to a specific Windows printer, without a printer selection dialog. PrintText(nodialog,"Microsoft Print to PDF") Send a screen snapshot to a specific POSIX printer. PrintText("lpr -Pmx860")