Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Envelope Printing / Duplex Printer

edited May 2004 in General
I have an HP LaserJet 2300 that has duplex printing capability. It also has
two bins - one of which is used for special printing like envelopes. The
printer is nomally configured to print in duplex. I am using ReportBuilder
7.03.

The problem I have is that when printing #10 envelopes with TppReport
(PaperName = Envelope #10, Duplex = dpNone), the printer will print in
duplex mode. It does select the proper bin and prompt for insertion of the
envelope. The only solution I have found is to manually reconfigure the
printer before printing to avoid the duplex action.

Any suggestions would be appreciated.

Tom

Comments

  • edited May 2004
    Hi Tom,

    ReportBuilder uses the DEVMODE structure in the Windows API to control the
    printer device as you can see in the TppPrinter.PrinterSetupToDevMode method
    inside the ppPrintr.pas file. We have not had any issues like this before
    where these properties were not working. Are you able to print successfully
    to another printer? Which event are you setting Duplex = dpNone? If you
    are setting it at design time, be sure you are not resetting any of the
    printer properties in code.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2004
    Hi Nico:

    I have tried setting PrinterSetup.Duplex = dpNone immediately before the
    Print method and it seems as though this proeprty cannot change the
    pre-existing printer configuration. There are no event handlers specified
    for TppReport.

    I can print to other printers but none of these have duplex options so that
    test does not prove anything.

    Regards,
    Tom

  • edited May 2004
    Hi Tom,

    Are you printing from the Archive Reader? Does the LaserJet 2300 default
    printer setup have duplexing turned on? We have never seen an issue like
    this with setting the duplex settings. On our duplexing printer, there is
    no way (using software) to turn duplexing on for all documents unless you
    alter the printer settings manually after printing a document.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2004
    Hi Nico:


    I am printing with two possible options:

    DeviceType := dtPrinter;
    ShowPrintDialog := false;
    Print;

    or

    DeviceType := dtScreen;
    ShowPrintDialog := true;
    Print;

    We have never seen an issue like

    Yes, the default printer setup has duplexing turned on. My assumption was
    that the software command would override the default. Is that incorrect?

    Tom
  • edited May 2004
    Hi Tom,

    I installed the driver for the LaserJet 2300d printer and was able to
    confirm the behavior you are experiencing. It appears that HP has decided
    not to use the standard Windows API to control duplexing with this printer
    driver. I am unsure why this would be but it is not uncommon for the
    writers of device drivers to make custom additions to the DevMode structure
    in the Windows API containing a printer's specific settings. Please see the
    article below for more information.

    -------------------------------------------------
    Tech Tip: Configuring Printer Specific Options
    -------------------------------------------------

    The Report.PrinterSetup properties can be used to set the properties that
    are common to all printers. Internally RB applies these to the Windows
    DevMode structure.


    Report.PrinterSetup <----> Windows DevMode <-----> Printer Driver <--->
    Printer


    Printers often contains additional features, such as output bins, media
    types, etc. The Windows DevMode structure can contain a private area that is
    used the printer driver to store printer specific options. These can be
    configured by using the Printer Driver's built-in properties dialog. These
    options can theoritically be set programmatically, the trick is that you
    have to know where in the structure to store the option and what values are
    valid.

    The following example shows how to display the printer properties dialog and
    save the devmode for use within RB...

    http://www.digital-metaphors.com/tips/SavePrinterDevMode.zip

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2004
    Hi Nico:

    Thanks for the update; at least I know I am not crazy - at least in this
    instance.

    Tom
This discussion has been closed.