• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Can I add a print button to interactive pdf that would print only specific section of the document? In example pages from pdf bookmark.

Community Beginner ,
Jul 16, 2018 Jul 16, 2018

Copy link to clipboard

Copied

As in the title. I need to place the "print" button to my document that would print only chosen pages. "Execute a menu item" option in acrobat does allow to specify the range of pages automatically. Thanks for help!

TOPICS
PDF forms

Views

1.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 16, 2018 Jul 16, 2018

Copy link to clipboard

Copied

Yes, but you'll have to use JavaScript. Here's a link to the documentation: Acrobat DC SDK Documentation

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 16, 2018 Jul 16, 2018

Copy link to clipboard

Copied

Yes, you can do it using a script. Here's a simple example of how to print pages 2-5:

var pp = this.getPrintParams();

pp.firstPage = 1;

pp.lastPage = 4;

this.print(pp);

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 16, 2018 Jul 16, 2018

Copy link to clipboard

Copied

Thank you guys! It works

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

One more question: this solution works properly when document is viewed in Acrobat, but does not work when document is opened in web browser. In chrome button opens print dialog, but page range is set to whole document by default (seems that chrome ignores a part of the script). In firefox it does not work at all (probably because it does not support pdf forms anly longer). Not to mention Edge, where every interactive element displays quite strange... Suprisingly, in Internet Explorer everything works fine.

Is it possible to use script which would avoid this struggles?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

No. The issue is with the faulty PDF plugins used by these browsers (IE uses Adobe Reader, so it works fine there).

You should instruct the users not to open the file inside the browser if they want it to work correctly, but to save it locally and then open it using Adobe Reader.

Also, you should complain to the developers of these applications about their shoddy work.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

Ok, thank you try67​. I was affraid that it is the matter of plugins...

Thanks a lot!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

Actually, try this code. It's the only other way of doing it using a script:

this.print({nStart: 1, nEnd: 4});

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

Tried this one, but gave the same results...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 17, 2018 Jul 17, 2018

Copy link to clipboard

Copied

That's what I thought would happen, but worth a shot, I guess...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 02, 2020 Nov 02, 2020

Copy link to clipboard

Copied

LATEST

All PDF form makers should know this great trick:
https://www.abracadabrapdf.net/ressources-et-tutos/creation/forcer-utilisation-pdf-avec-acrobat-read...
(Google translate is your friend)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 02, 2020 Nov 02, 2020

Copy link to clipboard

Copied

I've been scouring the Interwebs for an hour looking for this.  I'm running AA Pro DC Ver 2020.0012.20048 on a Mac.

 

Thank you so much.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines