printerFile.close()

API Overview

The printerFile.close() API is used to manually close a printer file defined with pjs.definePrinter().

RPG Equivalent

CLOSE

Contents

Exception Handling

An Error instance with the following properties will be thrown:

  • message - The IBM i message text.
  • error - The message id.
  • help - The message help text.

Examples

Manually open printer file
pjs.definePrinter("printer", { userOpen: true, overflowIndicator: "overflow" });
printer.open();
print.write();
print.close();