?
Solved

How to print 20cpi in dot matrix printers

Posted on 2003-03-27
5
Medium Priority
?
1,183 Views
Last Modified: 2007-12-19
We very well know chr(15)+text will print 15 cpi in dot matrix printers. But how to print 20 cpi ? What is the escape seq, to be sent. Iam using foxpro for dos and I need a tip to print the 20 cpi in dotmatrix printers.
0
Comment
Question by:fox-ravi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
5 Comments
 
LVL 33

Expert Comment

by:CarlWarner
ID: 8287186
What kind of dot matrix printer?
0
 
LVL 33

Expert Comment

by:CarlWarner
ID: 8287238
Assuming it's an Epson or works in Epson emulation mode:

Some commonly used escape codes include (in decimal values)
- Reset (27, 64); Set page length in lines (27, 67, n - where n is a number from 1 to 127); Carriage return (13); Line feed (10); Form feed (12); Select 1/8-inch line spacing (27, 48); 10 cpi (27, 80); 12 cpi (27, 77); Select bold font (27, 69); Cancel bold font (27, 70); Select italic font (27, 52); Cancel italic font (27, 53); Turn underline on/off (27, 45, n - where n equals 49=ON or 48=OFF); Select condensed print (15); Cancel condensed print (18). For more escape codes, please refer to the Command Summary of your User's Manual. If you need to use advanced escape codes for programming purposes, you can purchase an ESC/P Reference Manual from The EPSON Store.
0
 
LVL 33

Accepted Solution

by:
CarlWarner earned 150 total points
ID: 8287326
At least for Epsons, it seems that you first must change from the default character width of 10cpi to 12cpi through a CHR(27)+CHR(77) string.  Then you turn on the condensed mode via a CHR(15) to further force the new 12cpi into a 20cpi mode.
0
 

Author Comment

by:fox-ravi
ID: 8288832
Yes.. But is there any single escape sequance to convert to direct 20 cpi.

Thanks

Ravi
0
 
LVL 33

Expert Comment

by:CarlWarner
ID: 8288907
No, there is not a single sequence in this case.

It's just the way they do it.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say 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

If you’re thinking to yourself “That description sounds a lot like two people doing the work that one could accomplish,” you’re not alone.
Make the most of your online learning experience.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Suggested Courses
Course of the Month8 days, 5 hours left to enroll

765 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