Solved

Printing to different trays.

Posted on 2001-08-30
6
400 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
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 

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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
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…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

760 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