Skip to main content
Known Participant
January 20, 2021
Answered

Printing Two Different Types Of Pages

  • January 20, 2021
  • 1 reply
  • 1223 views

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?

This topic has been closed for replies.
Correct answer try67

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);

1 reply

try67
Community Expert
try67Community ExpertCorrect answer
Community Expert
January 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);
Known Participant
February 17, 2021

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?

try67
Community Expert
Community Expert
February 17, 2021

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