JavaScript: Passing values in the print dialog box

Hello

I have a PDF page containg 8 pages. There is a button on the first page, print then on some boxes (Page1, Page2... Page8)

I want to open the print dialog box with already put page numbers in the selection boxes.

Example: If I checked page 1, Page 4 boxes, print dialog box then should display values Print rang > Pages [1.4]

How can I do this using javascript?

Please help me

Thank you

Faraz

Hi Faraz,

That's the problem, you cannot specify a print with gaps range.

XFA. Host.Print (1, "0", "7", 0, 1, 0, 0, 0);

The second parameter specifies the start page (based on a system of numbering from zero). '0' will be so printed on page 1 of the form.

The third parameter specifies the last page to print. So '7' will display the page 8 of the form.

Here are some of the only solution I can think. Basically, the button opens the test set up dialogue (not the standard print window). This allows the user to select the right printer and settings. Then, the script looks like each page in turn and prints is as a standalone print job. If you look at the print command, you will see that the first parameter is set to '0', it is to print the page without displaying the print dialog. The fourth parameter is now on '1' to prevent the user to cancel the print job. If you look at the help file, you will get a complete description of the print command and all eight parameters.

xfa.host.print(0, "0", "0", 1, 1, 0, 0, 0);

Hope that helps,

Niall

Tags: Adobe LiveCycle

Similar Questions

  • How to call the print dialog box as soon as pdf is open?

    A pdf template has been created using adobe livecycle, then the final pdf is created using pdfMerger. Is there a way to call the print dialog box whenever the PDF is opened? Y does it have that no thate javascript should be used?

    I've never used a pdfMerger, but have you tried the following in the docReady event as suggested earlier?

    event.target.print();
    
  • 27.0 Firefox fails to open the print dialog box

    I have firefox set to update automatically. All of a sudden, perhaps after the most recent update, I can't print anything. If I try to print, I just get an audio windows error and nothing more. I don't get the print dialog box.
    I tried to reset the configuration of the printer, and I tried to reinstall Firefox all together. Neither sovled the problem.
    Please advice.

    Thank you.

    new information in bug reports seem to link it to avast.

  • Why Firefox doesn't open the printer dialog box whenever it starts

    When Firefox opens the printer dialog box opens automatically - why and how can I make sure that he does this.
    This never used to happen on previous versions of firefox

    Some web pages automatically shows the print dialog box. In particular, the pages Web sites have specially formatted for printing can do.

    Restore you tabs that you have opened previously, or commissioning with your home page (s)? I suspect that one of them generates the dialog box. You can view by clicking on each of them and reload the page to see if it's on this page.

  • I can't and never been able to open a file that was previously saved on hard disk by selecting the print option to get in the print dialog box

    I can not and never been able to open a file that was previously saved on hard disk by selecting the print option to get in the print dialog box. Firefox displays gooblygook, even if the name of file is an html element, the Notepad of Windows crashes, MS Excel does not recognize the file type. MS Word also displays goobblys when the file has no file extension.

    If you use the file printing, then you will get a file that is supposed to be sent to a printer, and this file has any sort of code formatting for this printer.

    Open such a file in Firefox or a text editor can only work if you use one printer for text to print the file to, then make sure that such a printer is installed and selected.

  • HP Photosmart B9180: paper Photosmart Pro B9180 profiles do not appear in the print dialog box

    I use my Photosmart Pro B9180 with Apple OS X Yosemite 10.10.3

    The printer prints fine, but I recently lost all my paper profiles in the print dialog box.

    Do you know how can I reconnect?

    Please help because I want to continue to use this printer very well!

    I solved the problem is Apple Support & Download HP Driver 3.1 updated.

    Then using the HP utility to reload the printer profiles.

  • CC of Photoshop crashes in the print dialog box.

    Photoshop CC2015 crashed in the print dialog box. I use 10 64-bit and Windows printing via a TCP/IP port to a printer Xerox 700i Protocol. The dialog box is very slow to react to clicks, and most of the time that it blocks just close photoshop.crashed.jpg

    The driver is blocked due to a bug in the driver code.

    Most other applications use the same APIs of modern printing such as Photoshop and so use code different in the driver.

    The manufacturer of your printer should know this and need to debug the problem instead of blaming the software from third-party manufacturers.

    Experience more, you can try: hold down the space bar while you select print in Photoshop. That make Photoshop will not load the last used settings of the printer, which is something that we have seen the cause crashes in some drivers (different causes of crash, but apparently this code path doesn't get tested).

  • I am trying to print a picture 5 x 7 that have been saved in PDF format, the print dialog box will only print it as an 8 x 10, any thoughts?

    So I guess that was supposed to be the subject line!  I would like to print a picture on paper photo 5 x 7, I did it in the past, but now I don't see an option to change the size of the paper.  I would greatly appreciate any comments.  Thank you

    Hi Sunshine58,

    Have you tried to click on the Page Setup button at the bottom left of the print dialog box? Who will show you the print options that provides the operating system, and you should be able to choose the page size of 5 x 7.

    Best,

    Sara

  • HP Officejet 7612 large Format: Printer e-all-in-one-HP Officejet 7612 large Format printing paper selections not available in the printer dialog box

    Using Adobe Acrobat Reader DC to print the PDF to your computer. Print dialog box displays all the options paper size whatever the configuration by default or the selection of the paper size in the printer configuration. 11 x 17 paper in the printer and configured by default. Only four options are available: letter, legal, A4, and Executive. Nothing is wider than 8.5 "is available, and this so-called parameters up to 13 X 19 printer.

    Hello

    Thank you for using the HP forum.

    You can download and install the software COMPLETE features of HP printing for your operating system:

    http://support.HP.com/SG-en/drivers/selfservice/HP-OfficeJet-7610-wide-format-e-all-in-one-series/5153788/model/6879040#Z7_3054ICK0K8UDA0AQC11TA930O2

    Please select the appropriate operating system.

    Once you have downloaded and installed the software, FULL of features, you will be able to print and scan.

    The desired print sizes should be there.

    Hope that helps.

  • How to create a new preset in the print dialog box?

    When you press the printer button a new printer dialog box opens. One of the choices is pre-set. How do you create new presets?

    Hi mholstein,

    Once you've applied print settings in Lightroom, you can click the plus sign next to model browser to create the preset

    Refer to this tutorial: make a Lightroom preset impression in - YouTube

  • small problem with the printer dialog box

    I recently added a Brother printer to my IMac and ran into a minor problem.  When I put in place using my WiFi and AirPrint, the dialog box has a convenient box for the black and white that I was able to check in one easy-to-replace step and just print in color.  However, the alarm time and the answer is a bit slow.  So, I then plugged a cable and add this version of the printer.  Now the box is missing and nothing I've been able to do, to delete and add new printer allowed me to bring that?  Any ideas on how I can get this feature practice appears in the dialog box with the printer connected to the cable?  Thank you.

    If I understand correctly, you have now two entries separated for this printer to Print & Scan? It's OK, although AirPrint is better for various reasons.

    I understand the printer takes an unacceptable amount of time to wake up to when choosing the AirPrint printer, and you want to avoid this.

    If you have added a separate entrance - one for the USB printer connected - how who you? Did you leave the print & Scan install this printer automatically on its own, or did you download and install a driver of brother separately?

  • Printer appears online in devices and printers, but in offline mode in the print dialog box

    After I plugged an inkjet printer from Canon iP4000 in my computer running Windows 7 SP 1 Ultimate 64 - bit edition, the printer is displayed correctly in devices and printers as a printer online but appears offline in print dialog common used by applications.

    Sometimes, I am able to print despite the problem, but as a general rule, the monitoring software will say that the printer does not Canon.

    In addition, a WiFi adapter sometimes loses the WiFi connection and is unable to find all the networks.

    Tried many things:

    • Uninstall of the printer
    • Manually clearing print jobs
    • Reset
    • Unplug the printer from a USB hub and connect directly to a USB port on the monitor

    I can not easily plug the printer to the computer directly because of the locations of the case of the printer and the computer. I tried to connect the printer directly to my ThinkPad and the printer does work very well in this situation.

    This who can I try to do at this point?

    > modifications

    N ° the problem occurs even after a new installation of Windows.

    > wired / wireless

    Wired

    > Error message

    N °

    I already tried all 4 of the links.

    The printer is dead and the 'solution' is to Canon printer in an electronic recycler so buy a Brother laser printer that takes in charge of wireless network.

  • I can't ' print using firefox. Preview print does not appear, is not the print dialog box, printing doesn't appear, etc.

    Looks like that since I've updated for firefox 5, I cannot print web pages, won't work not preview before printing. I click on the print under file option and nothing displays or prints.

    Try Firefox SafeMode and see if you can print from Firefox.

    A way of solving problems, which disables most of the modules.

    (If you use it, switch to the default theme).

    1. You can open the Firefox 4, 5, 6, 7 SafeMode pressing the SHIFT key when you use the desktop Firefox or shortcut in the start menu.
    2. Or use the Help menu option, click restart with the disabled... modules while Firefox is running.

    To exit safe mode of Firefox, simply close Firefox and wait a few seconds before using the shortcut of Firefox (without the Shift key) to open it again.

    If it's good in Firefox SafeMode, your problem is probably caused by an extension, and you need to understand that one.

    http://support.Mozilla.com/en-us/KB/troubleshooting+extensions+and+themes

  • No color management errors appear in the printer dialog box

    I agree with the CC. I use a Mac 10.9 and Epson 2400 printer. My printer quit allowing to "Photoshop to manage colors", I get an error that I try to print without color management. It happened during the night or when I did the PS was last updated. I tried Adobe Color Manager but it was useless. How can I get my old presets to work?

    Thank you

    OK, I FINALLY understood what happened. When I created a PS document to put the image on (it's for a show on paper 8 x 8), I inadvertently put the color profile of the image on the paper Hahnemehule profile. This is what confuses the printer. I switched it to ADOBE 1998 and it worked. Thank you for your time and great ideas. I have them all.

  • Where are the labels on the buttons in the print dialog box?

    I have a pc with Windows 7 64 bit system.

    I used Adobe Reader for years, I used XI for awhile.

    Now when I open a pdf file and try to print, the labels are all empty - no text, I have to guess on the buttons to select.

    The number of prints, duplex, portrait or landscape, including the pages to print, etc.

    Here's a good place to start---> dialog empty or missing GUI text

Maybe you are looking for