print postscript file from command line in window 
Author Message
 print postscript file from command line in window

in unix, i can call lp <filename>.ps to send a postscript file to the
printer.  is there a equivalent command
in window that i can send a postscript file to printer from the dos prompt?
without installing ghostview?


Tue, 30 Dec 2003 04:47:09 GMT  
 print postscript file from command line in window


Quote:
> in unix, i can call lp <filename>.ps to send a postscript file to
> the printer.  is there a equivalent command in window that i can
> send a postscript file to printer from the dos prompt?  without
> installing ghostview?

In the old DOS days, COPY FILENAME.PS PRN (or LPT1 or whatever) would
work, and there was even a TSR print spooler that came standard with
DOS, but I'm not really sure how all this works within a DOS box under
Windows...

--%!PS
10 10 scale/M{rmoveto}def/R{rlineto}def 12 45 moveto 0 5 R 4 -1 M 5.5 0 R
currentpoint 3 sub 3 90 0 arcn 0 -6 R 7.54 10.28 M 2.7067 -9.28 R -5.6333
2 setlinewidth 0 R 9.8867 8 M 7 0 R 0 -9 R -6 4 M 0 -4 R stroke showpage



Tue, 30 Dec 2003 05:02:53 GMT  
 print postscript file from command line in window

Quote:
>in unix, i can call lp <filename>.ps to send a postscript file to the
>printer.  is there a equivalent command
>in window that i can send a postscript file to printer from the dos prompt?
>without installing ghostview?

Sure, provided it's a PostScript printer.

COPY /B filename LPT1:

for example.
----------------------------------------

Visit http://www.*-*-*.com/ ,
PSAlter, psalters, tea, and small {*filter*} animals. And stuff.  



Tue, 30 Dec 2003 05:00:24 GMT  
 print postscript file from command line in window

Quote:
> in unix, i can call lp <filename>.ps to send a postscript file to
> the printer.  is there a equivalent command in window that i can
> send a postscript file to printer from the dos prompt?  without
> installing ghostview?

If the printer can do PostScript the PRINT command will do.  Try
PRINT/? at the prompt to get a short summary.


Tue, 30 Dec 2003 05:10:55 GMT  
 print postscript file from command line in window
If your printers is a network printer, it is a little tricker. In NT or
Winxx networks, you will probably need to use the NET USE command to asign
the network device name to the printer port:

NET USE \\machinename\printername lpt1

And the printer must be shared.


Quote:

> >in unix, i can call lp <filename>.ps to send a postscript file to the
> >printer.  is there a equivalent command
> >in window that i can send a postscript file to printer from the dos
prompt?
> >without installing ghostview?

> Sure, provided it's a PostScript printer.

> COPY /B filename LPT1:

> for example.
> ----------------------------------------

> Visit http://www.*-*-*.com/ ,
> PSAlter, psalters, tea, and small {*filter*} animals. And stuff.



Tue, 30 Dec 2003 06:39:38 GMT  
 print postscript file from command line in window

Quote:


> > in unix, i can call lp <filename>.ps to send a postscript file to
> > the printer.  is there a equivalent command in window that i can
> > send a postscript file to printer from the dos prompt?  without
> > installing ghostview?

> In the old DOS days, COPY FILENAME.PS PRN (or LPT1 or whatever) would
> work, and there was even a TSR print spooler that came standard with
> DOS, but I'm not really sure how all this works within a DOS box under
> Windows...

Make sure you add the /B
  copy /b filename.ps  \\server\printer_queue_name

RedPr.exe distributed with RedMon allows you to use the
queue name on the local computer.  To get the list of printer
queues:
  redpr
To print a file
  redpr -P"my printer queue name" file.ps
http://www.cs.wisc.edu/~ghost/redmon/



Tue, 30 Dec 2003 14:57:27 GMT  
 print postscript file from command line in window
Original message:

Quote:
>in unix, i can call lp <filename>.ps to send a postscript file to the
>printer.  is there a equivalent command
>in window that i can send a postscript file to printer from the dos prompt?
>without installing ghostview?

You may want to try the freeware program PrintFile, available in version
2.1.4 from its homepage http://hem.passagen.se/ptlerup/prfile.html (and in
many other places, of course).

The DOS commands "PRINT ..." and "COPY /B ... PRN" require an LPT port to
send the file to. For non-local printers, you need to establish a fake LPT
port. For Windows "Network" printers, this can be achieved in several ways,
the simplest of which is probably via the context menu in "Network
Neighborhood". Unfortunately, there doesn't seem to be a way to address
"Other" Windows printers (including TCP/IP network printers) as LPT ports.

In PrintFile "Settings", you can chose _any_ available printer just as you
do in other Windows applications. Anyway, you must make sure that "Show
printer selection dialog" is deactivated, otherwise printing from the
command line will not work the way you want it to. Now you can print from
the command prompt or from a batch file using "whatever_path\prfile32.exe
anyfile.ps". (If you don't like the PrintFile window to appear, you may
optionally include "/q" on the command line.) For a full description
including many advanced features (like n-up printing) see the help file.

Michael Hemmer



Tue, 30 Dec 2003 16:17:39 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. Printing an .rtf file from command line?

2. Close or control any windows app from command line or batch file by calling WinAPI

3. Passing values into and out of Command Line application *and* command line prompt in vbscript

4. Scripting command line applications & Command Line Prompting

5. Browser window opens behind command line window on 2000 machine

6. Browser window opens behind command line window on 2000 machine

7. Printing ascii files with embeded postscript commands on HP laserjet

8. dos command to print postscript file?

9. command line printing with ghostscript

10. Printing long lines using mp command

11. PCL to PDF Command Line Converter for Windows/DOS

12. Problems using network drives on ghostscript 6.50 command line (windows NT)

 

 
Powered by phpBB® Forum Software