Printing with WPViewPDF vs PrintIt.exe

  • I'm using wPDFView01.dll and I'm trying to print a .PDF file. It's actually Marco Cantu's Delphi2009HandbookCodeGear.pdf. (Just trying to printing a large file.) It's 3,744,863 bytes in size.

    My test code is the following (printing to the default printer):
    PDFViewer.FileName := GS_.FaxDir + Item.Caption;
    PDFViewer.CommandEx(COMPDF_PrintDialog, 0);
    PDFViewer.CommandStr(COMPDF_Print,'1-999999');

    The file does not print. Nothing happens. But when I use PrintIt.exe and point to the same file, it prints just fine. Can you share the code that PrintIt.exe uses to actually print a file? Is there something I need to add in my little routine to test for some condition or what?
    Also, what's the correct syntax to print all pages with COMPDF_Print?

    Thanks.
    Barry
    Jacksonville, FL