Skip to content

PrintJobOptions

new PrintJobOptions()

Contains information about how the job is to be printed.


printJobOptions.artboardRange

The artboard range to be printed if printAllArtboards is false.

Default: 1-

String


printJobOptions.bitmapResolution

The bitmap resolution. Minimum: 0.0.

Default: 0.0

Number (double)


printJobOptions.collate

If true, collate print pages.

Default: false

Boolean


printJobOptions.copies

The number of copies to print. Minimum: 1.

Default: 1

Number (long)


printJobOptions.designation

The layers/objects to be printed.

Default: PrintArtworkDesignation.VISIBLEPRINTABLELAYERS

PrintArtworkDesignation


printJobOptions.file

The file to which to print.

File object


printJobOptions.name

The print job name.

String


printJobOptions.printAllArtboards

Indicates whether to print all artboards.

Default: true

Boolean


printJobOptions.printArea

The printing bounds.

Default: PrintingBounds.ARTBOARDBOUNDS

PrintingBounds


printJobOptions.printAsBitmap

If true, print as bitmap.

Default: false

Boolean


printJobOptions.reversePages

If true, print pages in reverse order.

Default: false

Boolean


printJobOptions.typename

Read-only. The class name of the object.

String


// Creates a new document with layers containing visible, printable,
// non visible and non printable items then prints with each designation
// to view effects of using different job options
var docRef = documents.add();
var textRef_0 = docRef.layers[0].textFrames.add();
textRef_0.contents = "Visible and Printable";
textRef_0.top = 600;
textRef_0.left = 200;
var layerRef_1 = docRef.layers.add();
var textRef_1 = layerRef_1.textFrames.add();
textRef_1.contents = "Visible and Non-Printable";
textRef_1.top = 500;
textRef_1.left = 250;
layerRef_1.printable = false;
var layerRef_2 = docRef.layers.add();
var textRef_2 = layerRef_2.textFrames.add();
textRef_2.contents = "Non-Visible";
textRef_2.top = 400;
textRef_2.left = 300;
layerRef_2.visible = false;
redraw();
// Print with various job options
var printJobOptions = new PrintJobOptions();
var options = new PrintOptions();
options.jobOptions = printJobOptions;
printJobOptions.designation = PrintArtworkDesignation.ALLLAYERS;
printJobOptions.reverse = true;
docRef.print(options);
printJobOptions.collate = false;
printJobOptions.designation = PrintArtworkDesignation.VISIBLELAYERS;
printJobOptions.reverse = false;
docRef.print(options);
printJobOptions.designation = PrintArtworkDesignation.VISIBLEPRINTABLELAYERS;
var docPath = new File("~/printJobTest1.ps");
printJobOptions.file = docPath;
docRef.print(options);