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

Report Builder and Epson TM Till Printer

edited August 2005 in General
Hi

I am using RB 9.x Enterprise ? ( I have RAP and DADE ) and I am trying to
write reports that will work for both a standard A4 printer and for a
Receipt Printer ( via a Windows driver ). So far, the A4 works a treat, but
how do get it to print correctly over the A4 length on an Till Printer, I
have tried the Roll Paper settings and that doesn't seem to work - All
attempts I have made result in the printout having 2 pages, where the
heading is printed on both and the paper is not cut until the end.

How do I get this to work ? The same report has to work on A4 printers (
lasers ) or any Till Printer with a Windows driver.

Thanks
Tony

Comments

  • edited August 2005
    Hi Tony,

    First, where are you changing the PrinterSetup settings when you want to
    change printers? Will this need to happen on the fly or perhaps will you be
    printing a receipt and paper report simultaneously?

    Take a look at the following article on printing to a continuous paper
    printer. It may give you some clues on how to set up your report.

    ----------------------------------------------------
    Article: Printing to Continuous Paper
    ----------------------------------------------------

    1. Layout

    For continuous printing (for example a receipt) use Title/Summary and
    removing the Header/Footer. Set the PrintHeight of each to phDynamic. Layout
    the DetailBand to print a single line item. Set the margins to 0 or to the
    smallest that the printer driver will support (some printers have an
    unprintable area).

    With this configuration The Report will generate a Title followed by a
    variable number of Detail bands that span pages if needed, and then finally
    print a Summary at the end.

    2. Pagination

    a. dtPrinter

    Some printer drivers have a continuous paper size setting. If not then try
    setting the paper size to be very small - perhaps the size of the tallest
    band in the layout. Or try setting the page height to be the size of a
    detail band. Note that some printer drivers will only accept page sizes
    within a certain range of paper sizes.

    b. dtReportTextFile

    With the above layout, the report text file will generate the page breaks
    properly, however the device will fill up a page with blank lines. You can
    control the number of lines per page by configuring the CharacterGrid
    property in the Report.BeforePrint event:

    example:


    procedure TForm1.ppReport1BeforePrint(Sender: TObject);
    var
    lDevice: TppReportTextFileDevice;
    begin

    if (ppReport1.FileDevice <> nil) and (ppReport1.FileDevice is
    TppReportTextFileDevice)then
    begin
    lDevice := TppReportTextFileDevice(ppReport1.FileDevice);

    {120 characters per line, 66 lines per page}
    lDevice.CharacterGrid(120, 66);
    end;

    end;

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.