Link to home
Start Free TrialLog in
Avatar of kwang080897
kwang080897

asked on

Changing Paper Tray when Printing

Hi all !!

I would like to be able to Change the Printer Tray in my program, So it is possible to print the first page from the upper tray and the rest from the lower tray.

Is there a generel way to do this, whitout knowing what kind of printer it is.... I know the printer might not have more than one tray, but in those cases it schould be ignored

Avatar of okemoto
okemoto

This is dependant on the printer driver and hardware and is highly proprietary in nature. You would need to not only check the printer/driver attached, but you will also need the printer specific API since this is not a "standard" printing option even under Windows.
Avatar of kwang080897

ASKER

Okomoto :

Hi !

Thanks for participating, i will just reopen this question for a few days.

You might be right, and if thats the case i will of course grade you answer.

but i really need this function, and i just can't bellive It can't be done in a more generel way.

I can see that in Word 97 it is posible to use one tray for first page and another for the rest.

That way would work for me to... (to obtain a list of trays and choose)

Kim
Hello Kwang,

A few months ago I had a similar problem. Posting question I got answer from Inthe.
There is a unit called Windows.pas in Borland\Delphi\Source\RTL\WIN directory.It contains a lot of definitions for paper sizes, paper bins etc. I'm sure you will find there what you need. See under headings <paper selections> and <bin selections>.
Hope helps.

Jo.
ASKER CERTIFIED SOLUTION
Avatar of Fatman121898
Fatman121898

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
yes see jo's last comment that is the way to change paper and bin sizes :-)
Hi !!!

Jo:

Thanks ! - I will test this in a few days and return.... Havent got the time now


Inthe :

Hope You enjoy the recykling, if this works i will be more than happy to reward you too - after all it is your solution.


Kim

I'll Be back in a few days
Almost Perfect !!

Except I'll have to Close the Printer with a Printer.Enddoc if i want to change the tray (oterwise Printer is Busy )- this means that my one job will look like more jobs when printing (using enddoc every time)...

Any suggestions ??
Sorry i dont know if its possible to change tray "on the fly" using delphi's tprinter object without enddoc :-(
Sorry !!!

I Forgot about this one.....

Fatman : Please post an answer

Inthe... I will submit a question for your old answer as well

Thanks


Kim
Well - guess you dont have to..... i could myself..