2 Replies Latest reply on May 28, 2015 3:26 PM by try67

    Is there a JavaScript to give user the option to cancel a print job?

    KBrown

      I have a document which will have "required" fields.  I have read in this forum that there isn't a way to stop the form from printing.  I have read and think I can put an app alert to let the user know they missed a required field (I'm relatively new to JavaScript and am learning on my own).  I've also read that there isn't a JavaScript which will cancel the print job.

       

      Is there a way to give the user the option to stop the print job before it is actually sent to their printer so they can go back to enter the missing information -- such as an app alert saying something like "Do you want to cancel this print request to fill in missing information?  Yes/No"?  I'm using Acrobat XI Pro on Windows 7.

        • 1. Re: Is there a JavaScript to give user the option to cancel a print job?
          Karl Heinz Kremer Adobe Community Professional

          No, the information you found is correct: You cannot cancel a print job

          once it's started. There is no way around this.

           

          What you can do is change your document while its being printed so that

          it's obvious that the form was not filled out completely. What I've done is

          the past is to have a watermark in the document that says something like

          "Form not filled out completely", or something that would indicate the

          state of the document, and then enable that watermark while the document is

          being printed, and then disable it again just after the print process

          finishes. You can do this using the Document Will Print and Document Did

          Print document actions (Tools>JavaScript>Set Document Actions).

          • 2. Re: Is there a JavaScript to give user the option to cancel a print job?
            try67 MVP & Adobe Community Professional

            You can't cancel a print job but if the user tries to print the file from a button that is in your form (that is, not from the built-in command in the application) then you do have full control on whether or not to call the print method. However, once it's called it can't be cancelled using a script.