Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
printer options
our business just purchased a new HP 4200 LaserJet printer with four paper
trays. We print documents which require three or four different colors of paper (page 1 red, page 2 green, etc.). I am trying to set up vb code that will select the correct trays for our empolyees automatically. Since the print menu which allows you to do this is an hp screen, not an excel one, i can't seem to access these options through excel vb. there doesn't seem to be an object library i can use in references. any ideas? kari |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
printer options
Kari,
Theoretically, you can use SendKeys to specify the printer settings. However, in my experience the results are messy and unreliable. What you can do is set up a number of different print queues that point to the same printer. These appear as if they are different printers and can be easily specified using Application.ActivePrinter in your code. This gives you the opportunity to set up different printing preferences for each "virtual" printer and switch between them. Another way I use to change printer settings is to write the output to a file using a standard set of printing preferences and then edit the headers in the file using VBA before sending the file to a print queue. This requires a lot of specialist knowledge of printer codes or a lot of investigative work, so might not be practical for most developers. -- John Green Sydney Australia "kari" wrote in message ... our business just purchased a new HP 4200 LaserJet printer with four paper trays. We print documents which require three or four different colors of paper (page 1 red, page 2 green, etc.). I am trying to set up vb code that will select the correct trays for our empolyees automatically. Since the print menu which allows you to do this is an hp screen, not an excel one, i can't seem to access these options through excel vb. there doesn't seem to be an object library i can use in references. any ideas? kari |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
printer options
thanks a bunch!
kari "John Green" wrote: Kari, Theoretically, you can use SendKeys to specify the printer settings. However, in my experience the results are messy and unreliable. What you can do is set up a number of different print queues that point to the same printer. These appear as if they are different printers and can be easily specified using Application.ActivePrinter in your code. This gives you the opportunity to set up different printing preferences for each "virtual" printer and switch between them. Another way I use to change printer settings is to write the output to a file using a standard set of printing preferences and then edit the headers in the file using VBA before sending the file to a print queue. This requires a lot of specialist knowledge of printer codes or a lot of investigative work, so might not be practical for most developers. -- John Green Sydney Australia "kari" wrote in message ... our business just purchased a new HP 4200 LaserJet printer with four paper trays. We print documents which require three or four different colors of paper (page 1 red, page 2 green, etc.). I am trying to set up vb code that will select the correct trays for our empolyees automatically. Since the print menu which allows you to do this is an hp screen, not an excel one, i can't seem to access these options through excel vb. there doesn't seem to be an object library i can use in references. any ideas? kari |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
tools options view window options | Excel Discussion (Misc queries) | |||
members on my network printer not able to print to default printer | Excel Discussion (Misc queries) | |||
Printer Multiple Worksheets with a particular Printer Setting | Excel Worksheet Functions | |||
Printer Options | Excel Discussion (Misc queries) | |||
how do I add more toolbar options to my right click options | Excel Discussion (Misc queries) |