Article View: comp.os.msdos.programmer
Article #144Re: How do you clear a printer buffer?
From: David Nye
Date: Wed, 04 Nov 1992 05:47
Date: Wed, 04 Nov 1992 05:47
16 lines
1259 bytes
1259 bytes
In article <schneide.720825393@aries>, schneide@aries.scs.uiuc.edu (Ken Schneider) writes:
> I'm just wondering how to clear the printer buffer using C
> or C++ commands. For example, if the paper jams while printing
> a list of files, I want to be able to stop the current job and
> empty the printer queue. Can anyone help? It doesn't seem like
> fflush and similar commands are the correct ones to use. Thanks!
There may be two printer buffers, one in your printer and possibly
a second one in your PC if you are using a print spooler like PRINT.
To clear the one in your printer you will need to send a printer-
specific escape code (see your printer manual). To clear PRINT's
queue you need to shell to DOS and tell PRINT to stop. In TC you
would use 'system("print /t")'.
David Nye
nyeda@cnsvax.uwec.edu
Technical Details
Message-ID:
<1992Nov3.234736.2087@cnsvax.uwec.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!saimiri.primate.wisc.edu!zazen!uwec.edu!nyedaReferences:
<schneide.720825393@aries>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!saimiri.primate.wisc.edu!zazen!uwec.edu!nyeda From: nyeda@cnsvax.uwec.edu (David Nye) Newsgroups: comp.os.msdos.programmer Subject: Re: How do you clear a printer buffer? Message-ID: <1992Nov3.234736.2087@cnsvax.uwec.edu> Date: 3 Nov 92 23:47:36 -0600 References: <schneide.720825393@aries> Organization: University of Wisconsin Eau Claire Lines: 16