Re: How Do I Print to a second tray

From: Webb, Eric (EWEBB@COOPERLIGHTING.COM)
Date: Fri Apr 11 2003 - 10:11:47 EDT


I believe there are places in smit (Print Queue Characteristics and/or the
Printer Attribute Database) to force output to a different tray or paper
size, but in our case we had an application that was not specifying the page
size in its postscript output. Because of this, and because we wanted one
print queue to do both "A"- and "B"-sized prints, we used a shell script and
a small amount of logic to add one of these two postscript clauses to the
top of the .PS output file:

A-sized:
<</DeferredMediaSelection true /PageSize [612 792] >> setpagedevice
<</DeferredMediaSelection true /PageSize [792 1224] >> setpagedevice

B-sized:
<</DeferredMediaSelection true /MediaPosition 0 >> setpagedevice
<</DeferredMediaSelection true /MediaPosition 1 >> setpagedevice

Eric

-----Original Message-----
From: Bruce Whittaker [mailto:bwhittak@ENERGY.COM.AU]
Sent: Thursday, April 10, 2003 11:28 PM
To: aix-l@Princeton.EDU
Subject: How Do I Print to a second tray

Hi all,

I've got a curious issue which may be a little off track (apologies). I have
a PCL printer (HP 5si) to which I'm trying to print a converted postscript
file - but I want it to go to tray 3. Text prints to the second tray fine
but not converted postscript.

My setup is as follows,

1. My Test Postcript file.
        ---------------------------------
                %!PS-Adobe-3.0
                statusdict begin
               2 setpapertray
               end clippath stroke showpage
        -----------------------------------

2. Convert a postscript file to PCL format using ghostscript.
        /usr/local/bin/gs -q -dNOPAUSE -sPAPERSIZE=a4 -sDEVICE=ljet3
-sOutputFile=MY_PCL_FILE < POSTSCRIPT.ps

3. Print the postscript file to tray 3.
        /usr/bin/qprt -u2 -PMY_PRINTER MY_PCL_FILE

If I issue the qprt com on a text file, the printer selects the correct
paper tray. If however I use ghostscript to convert a postscript file it
ends up on the default tray (tray 2).

I've tried changing the tray number in the postscript file between 0 and 3
to no avail.
I've tried setting up a printer queue which has the default tray set to tray
3. It again works for text only.

Any ideas ?

Bruce Whittaker,
CASS Support,
Extension 34193
External (02) 9269 4193.
----------------------------------------------------------------------------
------------
This e-mail may contain confidential or privileged information. If you
have received it in error, please notify the sender immediately via return
e-mail and then delete the original e-mail. EnergyAustralia has collected
your business contact details for dealing with you in your business
capacity. More information about how we handle your personal information,
including your right of access is contained at http://www.energy.com.au.
----------------------------------------------------------------------------
------------

This Email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this Email in error please notify the system manager. Please note that any views or opinions presented in this Email are solely those of the author and do not necessarily represent those of the company. Finally, the recipient should check this Email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this Email.



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:44 EDT