Hi,
How to change color/black&white settings of the printer at CR XI-2 runtime ?
I don't found a color property like rpreport.colormode....
For some reasons (customized and stored report parameters by users) i can't use the CR printer dialog box.
Thanks in advance for any help.
VINCENT
Here is my code (VB6) :
Private Sub IMPRIMER(p1, p2)
Dim sp As Printer
Dim x As String
Dim y As String
Dim n As Integer
Dim PrtS As Printer
n = IMPRIMANTEP.Copies: If n = 0 Then n = 1
For Each sp In Printers
If sp.DeviceName = IMPRIMANTEP.Nom Then Set PrtS = sp: Exit For
Next
Set Printer = PrtS
'Set DefaultPrinter = Printer
'DefaultPrinterName = Printer.DeviceName
Printer.TrackDefault = True
Printer.PrintQuality = IMPRIMANTEP.Qualite
If IMPRIMANTEP.NoirEtBlanc = True Then
Printer.ColorMode = vbPRCMMonochrome
Else
Printer.ColorMode = vbPRCMColor
End If
rptReport.SelectPrinter IMPRIMANTEP.Driver, IMPRIMANTEP.Nom, IMPRIMANTEP.Port
rptReport.DisplayProgressDialog = True
rptReport.PaperSize = IMPRIMANTEP.Papier
rptReport.PaperSource = IMPRIMANTEP.Bac
If IMPRIMANTEP.Paysage = 1 Then
rptReport.PaperOrientation = crLandscape
Else
rptReport.PaperOrientation = crPortrait
End If
If p1 = p2 Then
rptReport.PrintOutEx False, n, True, p1, p2
Else
rptReport.PrintOutEx False, n, True
End If
End Sub