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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with Settings of printer copies and printer name in CR and VB

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
This is the source code I'm using to print a CR 8 report from VB

With CrystalReport1 ( object CrystalReport )
.ReportFileName = "C:\Report1.rpt"
.SQLQuery = sql ' sql is a string with the query
.PrinterCopies = 5
.PrinterName = ' name of the printer
.WindowControls = True
.WindowState = crptMaximized
.Destination = crptToWindow
.PrintReport
End With

But with this code the settings of printer copies and printer name are not accepted by the application and it uses the default values for printer copies (1) and printer name ( default printer )

Do anyone of you know the solution ?

Thank you in advance
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top