Retrieving Printer Name
How do I retrieve the name of the printer chosen in the printer dialog? And
how do I initialize this? For example, the first time an app is run,
you'll see the name of the default printer. If the user changes the printer
to something other than the default, I need to use that newly-chosen
printer the second time the app is run. I tried "ppreport1.printerdialog."
but there is no printername property there. I have Acrobat Distiller
installed s a printer driver. If I chose to use this driver the first time
in the printer dialog, I always want to default to this driver for
subsequent runs of this application.
Thanks!
Debbie Erickson
how do I initialize this? For example, the first time an app is run,
you'll see the name of the default printer. If the user changes the printer
to something other than the default, I need to use that newly-chosen
printer the second time the app is run. I tried "ppreport1.printerdialog."
but there is no printername property there. I have Acrobat Distiller
installed s a printer driver. If I chose to use this driver the first time
in the printer dialog, I always want to default to this driver for
subsequent runs of this application.
Thanks!
Debbie Erickson
This discussion has been closed.
Comments
Two options:
1. Access the Printer object of the TppCustomPrintDialog and use its
PrinterName property.
uses
ppPrintr;
lsPrinterName := TppPrinter(ppReport1.PrintDialog.Printer).PrinterName;
2. Access the actual combo box used to display the printers in the
TppPrintDialog.
uses
ppPDlg;
lsPrinterName := TppPrintDialog(ppReport1.PrintDialog).cbxPrinters.Text
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Two options:
1. Access the Printer object of the TppCustomPrintDialog and use its
PrinterName property.
uses
ppPrintr;
lsPrinterName := TppPrinter(ppReport1.PrintDialog.Printer).PrinterName;
2. Access the actual combo box used to display the printers in the
TppPrintDialog.
uses
ppPDlg;
lsPrinterName := TppPrintDialog(ppReport1.PrintDialog).cbxPrinters.Text
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com