Hi there,

I've read several of the replies here and I noticed a flaw in your
reasoning. In Windows, printers are generally set up to print pages,
not single lines. In general, this means the printer works with
documents and it will print the page(s) after the connection to the
printer is closed again.

In your case, this just means you have to collect x lines of text
first, until you have enough to fill a page. Then you can send those
lines to the printer to have them printed.
Remember, in Windows, the printer will not start printing before you
tell it that the page or document is finished. Depending on your
printer settings, your printer will print directly after you go to a
new page or just when you close the printer document. In the latter
case, it could take a long while before it's done.

In general, it would be more logical to print these data lines to just
a simple text file instead of to a printer. With a text file, you
could simply use AppendFile to append text to the end of it. If you
need a printed copy, then print the text file.

A complex solution which probably doesn't work with any USB printer is
by just contacting the printer directly through the LTP-port. This is
pretty complicated stuff, though. And not advisable since it makes
your application very printer-dependant. (Because you need to send
commands to the printer that it will understand, and you need to be
able to translate any error message that you receive from the printer.

Again, printers are page-oriented, not line-oriented. You cannot print
less than a single page. (Except for not printing anything, of course.)

With kind regards,
X Katja Bergman.

--- In [email protected], soonhuat ong <[EMAIL PROTECTED]> wrote:
> 
> I want a free component that can help me to print the data line by
line as the following example:
> 
> var myprintstring : String;
> 
> for i := 1 to 5 do
> begin
>   myprintstring := 'This is Line ' + IntToStr(i);
>   // Print data here
> end;
> 
> So the output will looks something like this:
> 
>  
> 
> Output
> -------
> 
> This is Line 1
> This is Line 2
> This is Line 3
> This is Line 4
> This is Line 5
> 
> 
> Anyone can help me out ?
> 
>  
> 
>  
> 
> 
>               
> ---------------------------------
>  Start your day with Yahoo! - make it your home page 
> 
> [Non-text portions of this message have been removed]





------------------------ Yahoo! Groups Sponsor --------------------~--> 
<font face=arial size=-1><a 
href="http://us.ard.yahoo.com/SIG=12hro5tht/M=362335.6886445.7839731.1510227/D=groups/S=1705115362:TM/Y=YAHOO/EXP=1122992462/A=2894361/R=0/SIG=13jmebhbo/*http://www.networkforgood.org/topics/education/digitaldivide/?source=YAHOO&cmpgn=GRP&RTP=http://groups.yahoo.com/";>In
 low income neighborhoods, 84% do not own computers. At Network for Good, help 
bridge the Digital Divide!</a>.</font>
--------------------------------------------------------------------~-> 

-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to