Copy link to clipboard
Copied
I need to know if I can export to a protected pdf when I mouse up a button.
Copy link to clipboard
Copied
It's not a single-click procedure (at least, not unless you use a custom-made script to do it). You would need to export all the pages as images, then create a new PDF from those images, then password-protect that PDF, and even that is not 100% secure...
Copy link to clipboard
Copied
Depends. Can you install a script on the user's local machine?
Copy link to clipboard
Copied
I mean I need a .pdf with non able to copy functions.
Copy link to clipboard
Copied
Copy what? The PDF itself, or its contents? The former is not possible. The latter is possible (using a security policy) but it's very easily to get around it, since not all applications adhere to these policies, unfortunately.
Copy link to clipboard
Copied
Or is there a way in which all the contents of the form and shapes could be saved as image, but printed on another pdf? I need this, so the customers don't have the ability to edit quickly .
Copy link to clipboard
Copied
It's not a single-click procedure (at least, not unless you use a custom-made script to do it). You would need to export all the pages as images, then create a new PDF from those images, then password-protect that PDF, and even that is not 100% secure...
Copy link to clipboard
Copied
You can flatten the form, which converts all of the fields, comments (including any shapes you may have added, etc.) to regular page contents. You can save the flattened PDF to a new file. Users won't be able to edit it any easier than with an image-only PDF.
Here's a free JavaScript-based utility for Acrobat that make the process easy: UVSAR : Selective Flattener tool for Adobe Acrobat 8, 9 and X
Post again if you need help installing it.
Copy link to clipboard
Copied
Is there any other script that can do the same thing as this widget? I'm not allowed to install extensions in all computers since many of them have not permissions. I need it to be very simple and included in a button action. Once again, I need to save it as another document, which won't be able to edit easier.
Copy link to clipboard
Copied
If you can open the JavaScript console by pressing Ctrl+J, you can enter the following line of code:
flattenPages();
and with the cursor on that line, press Ctrl + Enter, or enter on the numeric keypad. This will execute that line of code which will flatten all annotations (fields, comments, links, etc.) to regular page contents. This is not a reversible operation, so be sure to have backups before you flatten and save.
Copy link to clipboard
Copied
Also, if you have Acrobat DC, you should be able to create a custom command that includes this line of code so that it's readily available. More info on custom commands: Create Custom Commands in Adobe Acrobat DC Pro - KHKonsulting LLC
Copy link to clipboard
Copied
This is my actual button JS Action:
var pp = this.getPrintParams();
pp.firstPage = 0;
pp.lastPage = 2;
flattenPages();
pp.printerName = "Foxit Reader PDF Printer";
this.print(pp);
I have this code available but I need to flatten to regular page contents. But I need to Add save the flattened PDF to a new file. So users won't be able to edit it any easier.
Copy link to clipboard
Copied
What that print to PDF code does is essentially the same as flattening, though flattening is safer since it doesn't lose things you don't want to (boring technical explanation intentionally excluded here). If you want to flatten and save, I'd suggest saving and then flattening. Did you want the file save in an automated fashion, or did you want to prompt the user to save to a user-chosen file name and location?
Copy link to clipboard
Copied
It's not possible to specify a file name when sending the PDF to a (virtual) printer, only when saving it directly as a local file.
As George mentioned, what you're doing is not much different from just flattening and saving the file, though.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now