Solved

Printing to different trays.

Posted on 2001-08-30
6
401 Views
Last Modified: 2012-05-04
Has anyone got any examples of printing to different trays for example for customer A Print 1st page to tray 1, rest on tray 2 for customer B print 1st page on tray 3, rest on tray 4...

thanks and regards,

Adam
0
Comment
Question by:adamgernon
6 Comments
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 6440518
I am not aware of ANY way to do what you think you want to do.  A print job is sent to the Printer as a SINGLE BATCH job, to be executed by the printer.  And as it is a SINGLE entity when it gets to the printer, all pages in that entity will be treated the same.  Anything else would be a very special case of the way the Print spooler behaves for that specific printer, and I doubt that there is any way to alter that behavior in your code.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 6440712
How are you printing?  Are you using the Printer object?
0
 
LVL 4

Expert Comment

by:PBuck
ID: 6440823
We send various single print jobs to different trays all the time while printing forms (letterhead, colored seperator, and of course white).

We do this by sending raw PCL commands to the printer, so I know that if you are using a PCL/PostScript printer - you should be able to have the same functionality.  But, we are using a program to convert an older XES language to PCL - so I do not know the exact PCL command or script.

What I would suggest is to use the following code/API to send raw characters to the printer:
http://www.planet-source-code.com/xq/ASP/txtCodeId.12410/lngWId.1/qx/vb/scripts/ShowCode.htm

*You will just have to determine the proper PCL commands.

btw - is the printer programmable?  Such as determining tray1=Letterhead, tray2=color ?

Hope this helps!~
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:adamgernon
ID: 6444088
It is through the word object model...
0
 
LVL 4

Expert Comment

by:PBuck
ID: 6445417
No ... the code above sends raw text thru to your desired queue (whether local or located on the LAN).

As for the printer being programmable, their are some larger models such as Lexmark and Xerox that allow programming of the trays.  So whenever it recieves an tray command, it will pull from the desired tray.
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 50 total points
ID: 6445461
adamgernon,

If you are using the MS Word object model you should be able to control the printing (including the trays).

Take a look at the PrintOut method and the PageSetup object.

Caveat: I have never done this, but I would assume that if you can do it manually with Word, you should be able to do it programmatically.

Anthony
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now