5 pts.
 VBA to print to specific printer with print button
In Access 2007 how do I use VBA code in my print button to print to a "specific printer" for my report.

Software/Hardware used:
ASKED: December 11, 2008  1:05 AM
UPDATED: December 12, 2008  6:14 PM

Answer Wiki:
If it is not necessary to do it in VBA code, you can go to the page setup on the report and set specfic printer there and it will save with the report. If you need to do it in VBA, you will need to open the report in preview mode. Then the following command may work; but I haven't tried it. (Note: Reports(0) is the current report that is being previewed) reports(0).Printer.devicename = "My Printer"
Last Wiki Answer Submitted:  December 11, 2008  9:05 pm  by  Randym   1,740 pts.
All Answer Wiki Contributors:  Randym   1,740 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Good information – I was not aware of this option. Just tried & it works fine.
One can always learn good tips from this type of forum.

 2,510 pts.