Home Devices

Change print name and output bin

edited October 2005 in Devices
RB Pro 7.04 and Delphi 7 Enterprise

I have saved a report to an archive file and now i need to print with
archive reader.
After the print dialog show, i need to know the name of the printer selected
and set the output bin based on printer name and document name.
I have explored PrinterSetup.PrinterName and PrinterSetup.BinNames of the
ArchiveReader object in the OnInitializePrinterSetup event, bat its not
reflect the printer selected.

How can i know the name of then printer selected and bin associated?

Tanks,
Angelo.

Comments

  • edited October 2005

    -------------------------------------

    Tech Tip: Detect PrinterSetup Changes

    -------------------------------------


    Q:

    I want to check the printer setup after the user has closed the print
    dialog, but the Report.PrinterSetup hasn't changed? Where is the
    PrinterSetup that the user just entered?


    A:

    The PrinterSetup object is assigned from the Report to the TppPrinter object
    of the PrintDialog. When then user changes the PrinterSetup, it is not
    reflected in the Report's PrinterSetup, unless Report.SavePrinterSetup is
    true. When SavePrinterSetup is true, then the changes the user makes to the
    PrinterSetup will be reflected the next time the user prints from the
    current instance of the Report. To access the PrinterSetup the user has
    entered, perform the following in the Report.OnPrintDialogClose event.

    uses
    ppPrintr;

    procedure TForm1.ppReport1PrintDialogClose(Sender: TObject);
    begin
    TppPrinter(ppReport1.PrintDialog.Printer).PrinterSetup;
    end;


    --
    Tech Support mailto:support@digital-metaphors.com
    Digital Metaphors http://www.digital-metaphors.com




    --
    Nard Moseley
    Digital Metaphors Corporation
    http://www.digital-metaphors.com



    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.