Question

I have to load a few hundred documents of various sorts from disk and produce one giant aggregated PDF.

My approach is to convert each document to PDF individually, then aggregate them.

I have been writing each PDF document to isolated storage as part of this process.

Is there are better way to do this?

Performance is a priority - this is client side.

Was it helpful?

Solution

Have you heard of Pdftk - http://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/ (free) - I use it to merge multiple pdfs into one.

In combination with BullZip PDF printer (free) - http://www.bullzip.com/products/pdf/info.php - I can basically create any PDFs I need.

I'm not sure if you can do any automation with BullZip, but with Pdftk you could certainly work with it through C# and System.Diagnostics.Process.

Here's a typical command line that I use:

pdftk folder1/file1.pdf folder1/file2.pdf folder2/file1.pdf cat output all_files.pdf

That merges the 3 files, in order, to all_files.pdf

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top