Solved

Printing pages of infinite length

Posted on 1998-11-22
1
147 Views
Last Modified: 2010-04-01
I'm using VC++ 6.  I have an app that prints to a grocery store type receipt printer.  The receipt printer, of course, just has a long spool of paper and does not come in "pages."  I've got the printing thing working OK by using members of CDC, but it keeps wanting to deal in pages and I just want to keep doing a TextOut and send a single EndPage() when I'm done.  At present, however, it prints about a legal page's worth of text and then doesn't print anymore.
Any thoughts?

(p.s., I had it all working fine using low level C functions using a file stream set to the stdprn, etc., but I really want to try to get it to use the device context so I can let the user select network devices, etc.)
0
Comment
Question by:dpt081598
1 Comment
 
LVL 14

Accepted Solution

by:
AlexVirochovsky earned 50 total points
ID: 1178419
I can't print all output in 1 page.
You must devide you output to pages(60 lines in Page, for example), and use StartPage/EndPage function.
In other case, Y coordinate of you output will be
> maxY(you can find it by GetDeviceCaps function) and
Windows ignore all you output.
Regards, Alex
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

863 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now