Expand my Community achievements bar.

Choose paper source when Printing

Avatar

Former Community Member

Hi there,

I have the code below in a button, but I was hoping there was a way to have the 'Choose paper source by PDF page size' checked when the user goes to print throught he host application (ie File>Print). If I put the code below in the prePrint event, then obviously I'll get an infinite loop.

Any help is appreciated thanks.

Script:

var

MyDoc = event.target;

var

pp = MyDoc.getPrintParams();

var

fv = pp.constants.flagValues;

pp.flags

|= (fv.setPageSize);

MyDoc.print(pp);  //I want to set the print parameters without instigating the actual print method

Kyle

0 Replies