Q: I have multiple pdf files in a directory that I want to print in
one job. Would merging all of the files together into one file be the
best method to do this? Can I not feed each document one by one into
an open/active print job?
-----------
A: There are at least three ways to print a PDF document using PDFNet.
Each approach has some benefits and drawbacks.
If you are using pdftron.PDF.Print.StartPrintJob() the only way to
print multiple PDFs in a single job is to merge them together. The
main disadvantage is that because this is a platform independent and a
very simple function there is not much flexibility. The advantage is
that this function is very simple to use and is also very efficient
(especially on Vista/Windows 7 and higher).
If you are using PDFDraw for printing (PDFDraw.DrawInRect(...)), you
are controlling the entire print process and you should be able to
print multiple documents in a single job. The main disadvantage is
that PDFDraw is generating bitmaps or GDI+ commands (depending on your
settings in PDFDraw class). As a result, the spool file may become
very large and pages may be slow to print.
A third option, which is optimal in terms of flexibility and
performance, is to use pdftron.PDF.Convert.ToXps (which is part of
PDFNet Convert-Add on) and then use StartXpsPrintJob to print the
resulting XPS file. This way you can control all print ticket (or
DEVMODE) properties yourself, you can print multiple documents in a
single job etc. The main disadvantage is that StartXpsPrintJob is not
available on Windows versions prior to Vista (e.g. XP), there is a bit
more programming, and it requires a license for PDFNet Convert Add-on.
For more information, please see:
Print ticket:
http://msdn.microsoft.com/en-us/library/dd374437(VS.85).aspx
http://msdn.microsoft.com/en-us/library/ff728890(VS.85).aspx
Print ticket:
http://msdn.microsoft.com/en-us/library/ff686808(v=VS.85).aspx