Home Devices

Print to invalid printername

Hi

When I try to print out at report using an invalid printer name nothings happens. How can I detect this

Code to reproduce:
var
rp: TppReport;
...
rp.DeviceType := dtPrinter;
rp.PrinterSetup.PrinterName := 'PrinterName'; //<-- Invalid printer name
rp.Print;
...

Jens Borrisholt

Comments

  • Hi Jens,

    The Report.PrinterSetup.PrinterNames property contains a list of all available printers. When selecting a printer, it is best to use this list or verify that the manually entered printer name exactly matches a name in this list.


    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
Sign In or Register to comment.