Printing Two Different Types Of Pages

New Here ,
Jan 19, 2021 Jan 19, 2021

Copy link to clipboard

Copied

So you know how when you go to Mailings in MS Word and you go to print an envelope.  When you print that envelope the printer knows to pull from the bypass tray based on the envelope.

 

This cannot be accomplished in code, however, is there a way to set the properties, by page, to print from the correct tray?

 

What I am trying to accomplish is to print the first page normally (8 1/2 x 11) and the second page (a manilla envelope in the bypass tray)

 

Is this possible?

TOPICS
How to, Print and prepress

Views

73

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct Answer

Most Valuable Participant , Jan 20, 2021 Jan 20, 2021
Yes, it's possible. Use this code to tell the printer to select the paper tray based on the page size: var pp = this.getPrintParams(); fv = pp.constants.flagValues; pp.flags = pp.flags | fv.setPageSize; this.print(pp);

Likes

Translate

Translate
Most Valuable Participant ,
Jan 20, 2021 Jan 20, 2021

Copy link to clipboard

Copied

Yes, it's possible. Use this code to tell the printer to select the paper tray based on the page size:

 

var pp = this.getPrintParams();
fv = pp.constants.flagValues;
pp.flags = pp.flags | fv.setPageSize;
this.print(pp);

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

I'm not sure how to modify this and I am not having any luck.  

 

Is there a way to just make the first page print from tray 1 and the second out of tray 2?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

Using a script? Only if each tray is defined as its own printer.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

I'm not sure how I would accomplish that.  I will have to dig into the printer settings and see if there is an option.  Can you give me a completed example of the code above so I can figure out how to change it to match what we are using?

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

The code above is complete. It will send each page to the tray that matches its paper size.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

Well that would be why my changes were not working.  Do I set this as part of the file itself or attach it to the print button?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Feb 17, 2021 Feb 17, 2021

Copy link to clipboard

Copied

LATEST

As a part of a button.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines