From: vtailor AT gte DOT net
Subject: Re: Quick and dirty lpr for text files
6 Jun 1998 22:27:33 -0700
Message-ID: <199806062148.QAA03192.cygnus.gnu-win32@smtp2.mailsrvcs.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: 8bit
To: gnu-win32 AT cygnus DOT com
Cc: vtailor AT gte DOT net

>   John F. Kolen (jkolen AT typhoon DOT coginst DOT uwf DOT edu)
>   Fri, 5 Jun 1998 11:18:57 -0500
>   
>       
>The following works well enough from Emacs and the command line (bash or MSDOG)
>for basic printing text files to the default printer.  It even supports
>piping (necessary for emacs).
>
>----------------------- cut here -----------------------
>@echo off
>if "%1" == "" goto NOFILES
>:LOOP
>start /m \Windows\Notepad /p %1
>shift
>if NOT "%1" == "" goto LOOP
>goto THEEND
>:NOFILES
>copy con \Cygnus\tmpprint
>start /m \Windows\Notepad /p \Cygnus\tmpprint
>:THEEND
>----------------------- cut here -----------------------
>
Actually, as long as we're tossing batch files around, the following
batch file is even quicker and dirtier:

----------------------- cut here -----------------------
@echo off
if "%1" == "" goto NOFILES
:LOOP
copy %1 lpt1
shift
if NOT "%1" == "" goto LOOP
goto THEEND
:NOFILES
copy con lpt1
:THEEND
----------------------- cut here -----------------------

The only problem with this batch file is that it does not work for
network printers, which was the reason I originally wrote print.c.


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".