summaryrefslogtreecommitdiff
path: root/texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex
diff options
context:
space:
mode:
Diffstat (limited to 'texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex')
-rw-r--r--texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex27
1 files changed, 27 insertions, 0 deletions
diff --git a/texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex b/texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex
new file mode 100644
index 00000000..38df5985
--- /dev/null
+++ b/texmf-dist/doc/latex/docassembly/examples/doc-saveas.tex
@@ -0,0 +1,27 @@
+\documentclass{article}
+\usepackage{docassembly}
+\usepackage{lipsum}
+
+\hypersetup{pdfpagemode=UseNone}
+
+% Look in the Adobe Acrobat JavaScript manual under the doc.saveAs() to see all the possible parameters.
+\begin{docassembly}
+% save a copy of this PDF for the archives
+var retn=\docSaveAs({
+ cPath: "\jobname-copy.pdf",
+ bCopy: true
+});
+% This method can also be used to make conversions, for example, you can save a PDF as a PNG
+% Here, we make a PNG image of each page in this document.
+var retn=\docSaveAs({
+ cConvID: "com.adobe.acrobat.png",
+ cPath: "\jobname.png"
+});
+\executeSave();
+\end{docassembly}
+
+\begin{document}
+
+\lipsum[1-30]
+
+\end{document} \ No newline at end of file