Board index » delphi » HELP - Printing Problem with Delphi 3.0 - How do i stop my printer for feeding the paper after EndDoc message ?

HELP - Printing Problem with Delphi 3.0 - How do i stop my printer for feeding the paper after EndDoc message ?

I use Tprinter.BeginDoc and Tprinter.EndDoc method to print object but I've
trouble using this function
because i don't want the printer to form feed the paper after the EndDoc
message. I just want to make
application that print a status of the system, and i don't want to use all
of my paper for only a few lines printed on the paper. Somebody help me
please....
Regard
Ery Punta Hw
Multimedia Division, Telkom
Jakarta NOC
e-mail : phu...@telkom.net.id
http    : www.telkom.net.id

 

Re:HELP - Printing Problem with Delphi 3.0 - How do i stop my printer for feeding the paper after EndDoc message ?


On Sat, 21 Feb 1998 17:23:00 +0700, "Ery Punta Hendraswara"

Quote
<phu...@telkom.net.id> wrote:
>I use Tprinter.BeginDoc and Tprinter.EndDoc method to print object but I've
>trouble using this function
>because i don't want the printer to form feed the paper after the EndDoc
>message. I just want to make
>application that print a status of the system, and i don't want to use all
>of my paper for only a few lines printed on the paper. Somebody help me
>please....
>Regard
>Ery Punta Hw
>Multimedia Division, Telkom
>Jakarta NOC
>e-mail : phu...@telkom.net.id
>http    : www.telkom.net.id

You have two options:

1: Set the paper size to as short a height as possible (usually 1")
and then at least you are only wasting 1" of paper per print.  This
would allow you to continue printing through Windows.

2: Write directly to the printer using this sample code:

  var
    OutFile: textfile;

  begin
    AssignFile(OutFile,'LPT1:');
    Rewrite(OutFile);
    Writeln(OutFile,'This is a text line.');
    CloseFile(OutFile);
  end;

We have a component in ReportPrinter Pro that does the same thing as
option 2 but allows you to write all over the page with much easier
positioning (nice for pre-printed forms coming out of dot-matirx
printers) but in your case for printing a single status line it would
be overkill.  Good luck,

Jim Gunkel
Nevrona Designs
http://www.nevrona.com

Other Threads