Start with a page.
Or a PDF you already have.
Write your first PDF from Java, assemble a document packet, or add page numbers and passwords to existing files. Pick a task to see the steps and code.
Find the Java example
for your next task.
Search by task or choose a workflow category. Each example opens its steps and source code.
Create PDFs
Build a new PDF document from Java.
Create a PDF
Create a new document and place content on its pages.
Open example →Add page numbers
Set page numbering as you generate a document.
Open example →Encrypt a new PDF
Apply encryption during document creation.
Open example →Password protect a new PDF
Set user and owner passwords.
Open example →Convert TIFF to PDF
Place TIFF image frames onto PDF pages.
Open example →Work with existing PDFs
Combine documents, split pages, add numbering, and secure existing PDFs.
Merge PDFs
Join two source files into one PDF.
Open example →Combine PDFs
Append multiple PDFs into one document.
Open example →Split a PDF
Save selected pages to separate files.
Open example →Add page numbers to an existing PDF
Stamp page numbers using a template.
Open example →Encrypt an existing PDF
Apply encryption to an imported document.
Open example →Password protect an existing PDF
Add password protection to an existing file.
Open example →Assemble a customer packet
Combine an invoice and terms document into one PDF.
import com.cete.dynamicpdf.merger.MergeDocument;
MergeDocument packet = new MergeDocument("invoice.pdf");
packet.append("terms.pdf");
packet.draw("customer-packet.pdf");