Printing PDF attachments with Javascript

Advocate ,
Sep 03, 2018

Copy link to clipboard

Copied

Is it possible to print a PDF and also the PDF attachments inside of it with Javascript?

Adobe Community Professional
Correct answer by Joel_Geraci | Adobe Community Professional

Yes - and the code is fairly straightforward.

However, can you describe the use case a bit more?

If you have control over the desktops that need to do this, then you'll be able to install a folder level script that will allow you to print the document and all of it's attachments with minimal user interaction.

If you were thinking of distributing the file and using a button to print everything, you're going to end up showing a dialog for each attachment being printed. I imagine that's not what you were hoping for.

Alternatively, if everyone is using Acrobat rather than Reader, then you can assemble the file and the attachment into a single hidden PDF that you then print.

TOPICS
Acrobat SDK and JavaScript, Macintosh, Windows

Views

430

Likes

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

Printing PDF attachments with Javascript

Advocate ,
Sep 03, 2018

Copy link to clipboard

Copied

Is it possible to print a PDF and also the PDF attachments inside of it with Javascript?

Adobe Community Professional
Correct answer by Joel_Geraci | Adobe Community Professional

Yes - and the code is fairly straightforward.

However, can you describe the use case a bit more?

If you have control over the desktops that need to do this, then you'll be able to install a folder level script that will allow you to print the document and all of it's attachments with minimal user interaction.

If you were thinking of distributing the file and using a button to print everything, you're going to end up showing a dialog for each attachment being printed. I imagine that's not what you were hoping for.

Alternatively, if everyone is using Acrobat rather than Reader, then you can assemble the file and the attachment into a single hidden PDF that you then print.

TOPICS
Acrobat SDK and JavaScript, Macintosh, Windows

Views

431

Likes

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
Sep 03, 2018 0
Adobe Community Professional ,
Sep 04, 2018

Copy link to clipboard

Copied

Yes - and the code is fairly straightforward.

However, can you describe the use case a bit more?

If you have control over the desktops that need to do this, then you'll be able to install a folder level script that will allow you to print the document and all of it's attachments with minimal user interaction.

If you were thinking of distributing the file and using a button to print everything, you're going to end up showing a dialog for each attachment being printed. I imagine that's not what you were hoping for.

Alternatively, if everyone is using Acrobat rather than Reader, then you can assemble the file and the attachment into a single hidden PDF that you then print.

Likes

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
Reply
Loading...
Sep 04, 2018 1
Advocate ,
Sep 04, 2018

Copy link to clipboard

Copied

Hi Joel,

It was for distributing the PDF. Now I’ll be creating a Portfolio, that can print all content in one go.

Thanks for taken the time to replay and ask.

Likes

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
Reply
Loading...
Sep 04, 2018 0
Adobe Community Professional ,
Sep 04, 2018

Copy link to clipboard

Copied

Generally I don't recommend that Portfolios be used anymore... though t I did LOVE them at one time but for this use case, a portfolio is the better option. Note that if you distribute the PDF as a link, be sure to set the link to download the PDF or it will open in a browser that doesn't know how to print a Portfolio.

Likes

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
Reply
Loading...
Sep 04, 2018 0
Advocate ,
Sep 04, 2018

Copy link to clipboard

Copied

I’m also afraid Adobe drop the Portfolio features...

Likes

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
Reply
Loading...
Sep 04, 2018 0