Combining PDF files
Combining the source code of two LaTeX documents can be pretty hard, especially if they are based on different classes. However, combining their PDF output is pretty easy.
How to do it...
We will use the pdfpages
package.
You can test it with the flyer example from Chapter 1, The Variety of Document Types, together with the form example from the current chapter. Let's get going:
Open a document and choose any class:
\documentclass{article}
Load the
pdfpages
package:\usepackage{pdfpages}
Begin the document:
\begin{document}
Include the first PDF file by using the command
\includepdf
. It takes the page range as an option. Use a dash (-)
for the whole page range:\includepdf[pages=-]{flyer}
Include the second PDF file:
\includepdf[pages=-]{form}
End the document:
\end{document}
Compile once, and look at the newly generated file, which contains both the flyer and the form.
How it works...
The pdfpages
package is primarily used for including PDF files in a LaTeX document, completely or partially...