From: vtailor AT gte DOT net Subject: Re: Quick and dirty lpr for text files 9 Jun 1998 22:31:13 -0700 Message-ID: <199806091546.KAA15458.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) > Mon, 8 Jun 1998 13:46:45 -0500 > > >>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. >Thanks for letting every one see version 1 of my script! BTW, >this works for networked printers: have the printer grab an lpt port. Ah, I will have to tell John Davis that, since he is convinced that the Windows version of slrn must have its very own winspool.lib printer code to reach his network printer. >The real problem is that the version 1 script does not work if you have a >postscript printer on the other end of the line. While the printer driver >does the routing for you, it does no conversion. You would need to enscript the >text file. Depending on the printer, the printer's driver has a hook that brings up its Dos driver when the copy command is used. I have a more serious question for you: What compiler are you using for your `popen' or `_popen' commands? The Mingw32 system passes an extra `-P' parameter to any program called by _popen. Hence, your batch file will not work, because it detects `-P' as a file, not a parameter. Also, `copy con' looks good on paper, but hangs in real time on my Windows 95 system, and I have tried it stripped down to a test program and running from the piped printer code in John Davis's slrn program. In fact, piping doesn't work all that well with crtdll.dll in general. Since I didn't want my students to have to deal with printer >drivers, I sent it through wordpad. > You mean notepad, or does wordpad also have an undocumented command line?  - 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".