How can I select printer by myself to print one report to any port printers?

  • Thread starter Thread starter thai
  • Start date Start date
T

thai

Please help me..
I have to print one report to the select port by the table.
How can I select printer by myself to print one report to
any port printers?
I using MS access XP..
Thank you
 
1.) Make sure that your report is set to use the default printer.

2.) In Access 2002 (Xp), you can set a target default printer at run time by
running a little function like this and supplying the printer name:

Private Sub SetPrinter (strPrinterName)
Dim objPrinter As Printer
For Each objPrinter In Application.Printers
If objPrinter.DeviceName = strPrinterName Then
Application.Printer = objPrinter
End If
Next
End Sub
 
Dear Steve...
If I want to print another printer that is not default
printer.
How to do ?
thank you very much...
 
Thai:

Just as shown below. Set your report to use the default printer and then
manage which printer is the default using the code below.
 
Back
Top