3 Replies Latest reply on May 12, 2009 9:55 PM by jay.lu

    How can I choose specific paper source(Tray) when print PDF use javascript


      I know we can set the printParams with 'setPageSize' to match the printer Tray automatic by paper size, while, in some cases, we have to choose the specific printer tray with the different paper quality.

      Is there any suggention to me?


                  JSObj = pddoc.GetJSObject()

                  numpages = pddoc.GetNumPages()

                  printerPara = JSObj.getPrintParams()

                  printerPara.printerName = strPrinterID
                  printerPara.DuplexType = printerPara.constants.duplexTypes.DuplexFlipLongEdge
                  OutputLogfile(" DuplexType:" & printerPara.DuplexType, "PrintPDFFile")

                  printerPara.flags = printerPara.flags Or printerPara.constants.flagValues.setPageSize
                  printerPara.interactive = printerPara.constants.interactionLevel.automatic