Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I have two Rpt.PrintReport but only print once >?

Status
Not open for further replies.

ChuyBCh

Programmer
Dec 14, 2001
4
MX
Hi there!
I need a report to print twice, I mean two copies, So I have in my code:
RptDataReport.PrintReport, False
RptDataReport.PrintReport, False

but It only sends one copy. This happend when I print on a remote printer, because when I Print in a local printer It works.
I add the follow msgbox and it works but I need the report to be printed without any click by the user.
msgbox "Print first copy"
RptDataReport.PrintReport, False
msgbox "Print second copy"
RptDataReport.PrintReport, False

Is any way to send two copies without putting the messagebox?


 
I found the solution.
Now I need to print in two different printers. I mean I want to print two copies in the default printer and more one copy (the third one) in another remote printer.
I'm trying with printer object I mean:
Dim X As Printer
For Each X In Printers
If X.DeviceName = "Name of the printer" Then
Set Printer = X ' Set printer as system default.
Exit For ' Stop looking for a printer.
End If
Next

but it is still sending the print on the default printer, not in the printer It is set.
Can Anybody know something about this case?
Thank's.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top