B4Print.com

Applications => Adobe Acrobat => Topic started by: DigiCorn on October 30, 2019, 10:43:04 AM

Title: Acrobat wants to print file after opening
Post by: DigiCorn on October 30, 2019, 10:43:04 AM
Lately, when I open a pdf, the print screen pops up. It's a minor annoyance, but I can't find the preference to turn off this option.

Also, before a new file opens, it shows the last opened file until the new one finishes opening up. Again, annoying.

HELP! :gom:
Title: Re: Acrobat wants to print file after opening
Post by: Joe on October 30, 2019, 11:46:57 AM
Haven't seen the print screen popup when opening a PDF yet. And don't see a preference that would make it. Must be an "undocumented" feature. :P

I do see the second one happen and it bugs me too. Never seen it before I upgraded to Mojave. I'm not a fan of Mojave.
Title: Re: Acrobat wants to print file after opening
Post by: AaronH on October 30, 2019, 12:53:11 PM
I have the second issue, and have since Sierra (Skipped High Sierra). I had the print screen thing on one file and I don't know what caused it but again it was only with one file.
Title: Re: Acrobat wants to print file after opening
Post by: jwheeler on October 30, 2019, 01:02:28 PM
I found this solution in another forum:


It turns out that it was a JavaScript issue. I must have somehow imported JavaScript that was causing the form to open the dialog box when I imported the original form file. To solve this, I opened the form in Edit mode, went to Other Tasks in the Form menu, and selected Document JavaScripts. From there, I just deleted the troublesome JavaScript code.

Here's what worked for me in Adobe Acrobat X:

(1) Run "Optimize Scanned PDF Images" under the menu on the right:

> "Tools" > "Document Processing" > "OptimizeScanned PDF Images"

-- During Scan, the process will stop at each Print Dialog Box.

-- Write down each page thatopens the Print Dialog Box

-- "Cancel" each Print function.

The scan process ends back at the first page. You now have a listing of all pages that invoke the JavaScript print command.


(2) Open the "Page Thumbnails" viewer on left menu

-- Enter the page number of the first identified page in thescan above.

-- "Cancel" the Print command

-- Right-Click in the Page Thumbnail of the selected page. And Select the following in the menu:

> "Page Properties"

> "Actions"

> "Delete"

> "OK"

Enter the next page number of the identified in thescan. Repeat the above delete process.

Continue until all JavaScript commands have been deleted forthe entire document.


(3) Save the PDF under a new name.
Title: Re: Acrobat wants to print file after opening
Post by: jwheeler on October 30, 2019, 01:05:04 PM
A couple of other responses in another forum:

Open in Adobe Acrobat. Goto tools > Javascript > choose "Document Javascripts". Then a dialog box pops up. There will be this.print() code with a corresponding script name (0 in my case). Just press delete botton in the dialog box and save.


In Adobe Acrobat 8 Professional the path is a bit different: Advanced > Document Processing > Document JavaScripts... > Press Delete in the pop-up dialog. – martias Jul 27 '18 at 6:38
This answer is incomplete, in that you have to turn off Enable Acrobat Javascript as @Sim K's answer says, in order to get past the print dialogue. (My document's script called this.print(); followed immediately by this.close().) I am going to add this answer's instructions to the accepted answer, to have one answer which gives the whole story.
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on October 31, 2019, 10:35:03 AM
Yeah... that doesn't work. This happens to me on random documents, and when it happened just now, I did what you described, but NO print dialogue boxes popped up when I run the scan. And none of the pages have any kind of script on them.
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on October 31, 2019, 10:42:51 AM
Here's a link to the glitch: https://www.dropbox.com/s/a1tl1v6s44g6qnd/Acrobat%20glitch.mov?dl=0
Title: Re: Acrobat wants to print file after opening
Post by: Joe on October 31, 2019, 12:13:26 PM
Can you post a PDF that it does this with so we can see if it does it for us? Also Acrobat DC right?
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on October 31, 2019, 12:37:37 PM
DC, Yes.
https://www.dropbox.com/s/2ipr92htdjl0qom/43734%20LM%20Financial%20Flyer.pdf?dl=0
Title: Re: Acrobat wants to print file after opening
Post by: pabney on October 31, 2019, 12:54:28 PM
Go to Tools->JavaScript->All JavaScripts and delete or comment out this line:

this.print({bUI:true,bSilent:false,bShrinkToFit:true});
Title: Re: Acrobat wants to print file after opening
Post by: Joe on October 31, 2019, 01:55:07 PM
Quote from: pabney on October 31, 2019, 12:54:28 PM
Go to Tools->JavaScript->All JavaScripts and delete or comment out this line:

this.print({bUI:true,bSilent:false,bShrinkToFit:true});

Yep...there is your document javascript.
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on November 01, 2019, 10:33:29 AM
That did it. Why the fuck is it there?

This was a customer supplied pdf.
Title: Re: Acrobat wants to print file after opening
Post by: Joe on November 01, 2019, 11:04:27 AM
Quote from: DigiCorn on November 01, 2019, 10:33:29 AM
That did it. Why the fuck is it there?

This was a customer supplied pdf.

You pretty much asked and answered your own question in that post.
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on November 01, 2019, 12:52:41 PM
Quote from: Joe on November 01, 2019, 11:04:27 AM
Quote from: DigiCorn on November 01, 2019, 10:33:29 AM
That did it. Why the fuck is it there?

This was a customer supplied pdf.

You pretty much asked and answered your own question in that post.
No kidding.

Bastards. All of them.
Title: Re: Acrobat wants to print file after opening
Post by: AaronH on November 05, 2019, 11:55:20 AM
My guess is they somehow had the print dialog open when they last saved the file, then closed acrobat. That's the only thing I could think of.
Title: Re: Acrobat wants to print file after opening
Post by: DigiCorn on November 05, 2019, 12:19:33 PM
Bastards. All of them.