?
Solved

Printing

Posted on 2001-06-12
7
Medium Priority
?
256 Views
Last Modified: 2010-04-06
Hi,

I am printing information to a line printer and I want it to stop ejecting to the end of page after each time I send. I want t continuously send without going to a new page. Is there a way to turn this off.

Thnx.
0
Comment
Question by:dvk
7 Comments
 
LVL 8

Expert Comment

by:Cesario
ID: 6180885
Hi dvk,

how do you send the lines to the line printer ?

AFAIK, you must send to the Printer an ESC Command..

Regards

Cesario
0
 
LVL 1

Expert Comment

by:mscatena
ID: 6180913
There could be a couple of things...

Each print job in Windows is a multiple of page by definition. One easy way is not to send "jobs" with Printer.BerinDoc/Printer.EndDoc but rather send the lines directly to the printer, like:

var
  f : TextFile;
begin
//  AssignFile(f, 'LPT1');
  AssignFile(f, '\\server1\epson810');
  Rewrite(f);
  WriteLn(f, Memo1.Text);
  CloseFile(f);
end;

You can send a "form feed" - Write(f, #12); - to force a page ejection.

You must also check if the printer is ejecting after the last line. This is controlled by an escape sequence.

Mauro
0
 

Author Comment

by:dvk
ID: 6180920
I've used two methods but didn't get it to stop. I'm currently using this.


AssignPrn(PrintText);
Rewrite(PrintText);
Printer.Canvas.Font := Memo1.Font;
for Line := 0 to Memo1.Lines.Count - 1 do
  Writeln(PrintText, Memo1.Lines[Line]);
CloseFile(PrintText);

0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 1

Accepted Solution

by:
mscatena earned 300 total points
ID: 6180960
It looks like it?s a setting in your printer.

Another way is to use the ?Generic / Text only? printer and adjust it?s properties so it uses continuous paper without like feed. Then you might eve use BeginDoc/EndDoc.
0
 
LVL 8

Expert Comment

by:Cesario
ID: 6180965
I agree with mscatena.
Just look in you Printer Manuel for the right ESC Sequenz
0
 
LVL 3

Expert Comment

by:VSF
ID: 6183097
Take a look at this link:
http://www.experts-exchange.com/jsp/qShow.jsp?ta=delphi&qid=20027475

Procedure TForm1.Button1Click(Sender: Object);
var
 Imp: TextFile;
begin
 AssignFile(Imp, 'LPT1');
 Rewrite(Imp);
 Write(Imp, 'Isto vai sair na impressora');
   
 Write(Imp, #27#69 + 'Bold Printing' + #27#70); {Bold}
 Write(Imp, #15 + 'Condensed mode' + #18); {condensed}
 Write(Imp, #12); { page jump}
 CloseFile(Imp);
end;

0
 
LVL 1

Expert Comment

by:Moondancer
ID: 6975871
One of your questions is reasonably current all others are not and need your attention.  ADMINISTRATION WILL BE CONTACTING YOU SHORTLY.  Moderators Computer101 or Netminder will return to finalize these if they are still open in 14 days.  Experts, please post closing recommendations before that time.

Below are your open questions as of today.  Questions which have been inactive for 21 days or longer are considered to be abandoned and for those, your options are:
1. Accept a Comment As Answer (use the button next to the Expert's name).
2. Close the question if the information was not useful to you, but may help others. You must tell the participants why you wish to do this, and allow for Expert response.  This choice will include a refund to you, and will move this question to our PAQ (Previously Asked Question) database.  If you found information outside this question thread, please add it.
3. Ask Community Support to help split points between participating experts, or just comment here with details and we'll respond with the process.
4. Delete the question (if it has no potential value for others).
   --> Post comments for expert of your intention to delete and why
   --> YOU CANNOT DELETE A QUESTION with comments; special handling by a Moderator is required.

For special handling needs, please post a zero point question in the link below and include the URL (question QID/link) that it regards with details.
http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
 
Please click this link for Help Desk, Guidelines/Member Agreement and the Question/Answer process.  http://www.experts-exchange.com/jsp/cmtyHelpDesk.jsp

Click you Member Profile to view your question history and please keep them updated. If you are a KnowledgePro user, use the Power Search option to find them.  

Questions which are LOCKED with a Proposed Answer but do not help you, should be rejected with comments added.  When you grade the question less than an A, please comment as to why.  This helps all involved, as well as others who may access this item in the future.  PLEASE DO NOT AWARD POINTS TO ME.

To view your open questions, please click the following link(s) and keep them all current with updates.
http://www.experts-exchange.com/questions/Q.20063066.html
http://www.experts-exchange.com/questions/Q.20133784.html
http://www.experts-exchange.com/questions/Q.20178269.html
http://www.experts-exchange.com/questions/Q.20189429.html
http://www.experts-exchange.com/questions/Q.20237069.html
http://www.experts-exchange.com/questions/Q.20287910.html



*****  E X P E R T S    P L E A S E  ******  Leave your closing recommendations.
If you are interested in the cleanup effort, please click this link
http://www.experts-exchange.com/jsp/qManageQuestion.jsp?ta=commspt&qid=20274643 
POINTS FOR EXPERTS awaiting comments are listed in the link below
http://www.experts-exchange.com/commspt/Q.20277028.html
 
Moderators will finalize this question if in @14 days Asker has not responded.  This will be moved to the PAQ (Previously Asked Questions) at zero points, deleted or awarded.
 
Thanks everyone.
Moondancer
Moderator @ Experts Exchange
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Are you ready to place your question in front of subject-matter experts for more timely responses? With the release of Priority Question, Premium Members, Team Accounts and Qualified Experts can now identify the emergent level of their issue, signal…
Suggested Courses
Course of the Month14 days, 15 hours left to enroll

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question