Operating System - HP-UX
1847578 Members
3387 Online
110265 Solutions
New Discussion

Printing legal landscape in command line

 
SOLVED
Go to solution
Jonathan Caplette_1
Super Advisor

Printing legal landscape in command line

Hi guys!!

I've a HP LaserJet 5000N with a Jetdirect card... This printer work fine if I print in a letter format... But I need to print in a legal - landscape format... What are the option when I use "lp"???

This printer have 3 tray... Can I specify a tray in the command line???

Thanks
Jonathan
6 REPLIES 6
Pete Randall
Outstanding Contributor
Solution

Re: Printing legal landscape in command line

Jonathan,

"lp -d wherever -o land" should give landscape mode. Tray selection should be "-o obin#" where the # indicates the tray "number".


Pete

Pete
Robert-Jan Goossens
Honored Contributor

Re: Printing legal landscape in command line

Hi,

# lp printername -o landscape -o tray3 filename

Robert-Jan.
A. Clay Stephenson
Acclaimed Contributor

Re: Printing legal landscape in command line

Your best option is to do something like this:

ls | lp -dmyprinter -o options

The -o options will list the available options for your interface file - or it may direct you to a man page that indicates the available options.
If it ain't broke, I can fix that.
Jeff Schussele
Honored Contributor

Re: Printing legal landscape in command line

Hi Jonathan,

When you denote
-o landscape
you automatically default to 45 lines per page. So unless you want to overrule that you need do nothing further to accomodate page length.

Use
-o legal
to set paper length to legal

Use
-o binX (where X = bin #)

So the command would look like

lp -o landscape -o legal -o binX -dptr_name /file/to print

HTH,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Bill Hassell
Honored Contributor

Re: Printing legal landscape in command line

Print a test page with the special option -ooptions (that's correct, -ooptions). lp is one of the only commands where there must be no spaces between an option (-o) ane the parameter (options). Something like this:

lp -lpprinter_queue -ooptions /etc/issue

But much more useful for JetDirect printers is the man page:

man net_lj5x

You'll find a enormous number of options used by the net_lj5x printer script.


Bill Hassell, sysadmin
Jonathan Caplette_1
Super Advisor

Re: Printing legal landscape in command line

It worked!

Thanks guys!