Printing in dot matrix printers
?I would like to print continuosly, with a custom made paper size. Each
sheet has 210mm width X 304,3mm height.
But when I print the report, it looks like reportbuilder used different
size of paper - The printing is Ok, but it does not go correctly to the
begining of the next page.
I am sure that I made some mistake with the properties of ppReport, but
I don?t know what it is.
Can you help me?
--- posted by geoForum on http://delphi.newswhat.com
sheet has 210mm width X 304,3mm height.
But when I print the report, it looks like reportbuilder used different
size of paper - The printing is Ok, but it does not go correctly to the
begining of the next page.
I am sure that I made some mistake with the properties of ppReport, but
I don?t know what it is.
Can you help me?
--- posted by geoForum on http://delphi.newswhat.com
This discussion has been closed.
Comments
printing to custom paper sizes...
----------------------------------------------------
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;
---------------------------------------------
Article: Troubleshooting Custom Paper Sizes
---------------------------------------------
Some printers cannot handle custom paper sizes, or they
can only handle custom paper sizes within a limited
range of values.
Troubleshooting Tips:
---------------------
1. To test paper sizes you can run demo 121 in the main reports demo app.
This demo displays a printer settings dialog and is very useful for
testing printer drivers with various paper sizes.
To test a paper size:
a. Selecting the printer
b. Specify the paper size
c. press preview
d. Press print to display the print dialog.
e. From the print dialog press the Properties button to display the
printer driver's built-in dialog. You should be able to verify the
printer setting from here.
These are the values communicated by RB to the printer. If
these are set correctly then RB has done its job, the rest is up to the
printer.
2. Try printing to this same paper size using other apps such
as MS Excel and MS Word. If they cannot do it, then it is likely
a limitation of the printer.
3. Try downloading the latest printer driver from the manufacturers
web site.
4. Try testing with another printer.
If test number 1 above works properly then e-mail
support@digital-metaphors.com with the exact configuration
you are using: Delphi version, ReportBuilder version,
OS XP/2000, Win9x), and printer model.
We can download the driver and try it out here.
--
Tech Support mailto:support@digital-metaphors.com
Digital Metaphors http://www.digital-metaphors.com
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
printed on continuous paper. I must have the following design:
3 files -> Invoice - Invoice Items - Payment Terms (installments)
For each invoice, I have many items and many payment terms (from 1 to 10)
So, my detail band has infact 3 Subsreports:
Header: file invoice (customer information)
Subreport 1 Invoice Items
Subreport 2 Payment Terms
Subreport 3 Invoice (totals)
I think that I made a real mess... Could you help me to fix that?
Regards
Layout
the
finally
try
tallest
breaks
can
app.
Each
different
the
but
--- posted by geoForum on http://delphi.newswhat.com
- configure the data so that you have three queries. The master will be
invoice and there will be two queries that are linked to the master - one
for items and one for payment terms. You can use the query tools of the RB
Data workspace to create the queries and visually link them.
Invoice query
InvoiceItem query
PaymentTerms query
- configure the report layout to use a main report and two subreports. The
main report will be connected to the master invoice query. The two
subreports will be connected to items and terms respectively. Set the second
subreport to ShiftRelativeTo the subreport that appears directly above it.
main - invoice
subreport1 - invoice items
subreport1 - payment terms
--
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com