In my code, I print a dataSet
' get grid's PrintDocument object
Dim pd As System.Drawing. Printing.PrintD ocument
pd = flexgrid.PrintP arameters.Print Document()
' set up the page (landscape, 1.5" left margin)
With pd.DefaultPageS ettings
..Landscape = False
..Margins.Left = 50
Dim a As New Printing.PaperS ize("Carta", 850, 1100)
..PaperSize = a
End With
' set up header and footer fonts
flexgrid.PrintP arameters.Heade rFont = New Font("Tahoma", 10, FontStyle.Bold)
flexgrid.PrintP arameters.Foote rFont = New Font("Tahoma", 10,
FontStyle.Regul ar)
' preview the grid
flexgrid.PrintG rid("Calificaci ones",
C1.Win.C1FlexGr id.PrintGridFla gs.FitToPageWid th +
C1.Win.C1FlexGr id.PrintGridFla gs.ShowPreviewD ialog, _
Now.ToString("d d/MM/yyyy") + vbCrLf + Now.ToString("H H:mm:ss") _
+ Chr(9) + ObtieneInformac ion("escuela") + vbCrLf + "Calificaci ones Periodo
" & ObtieneInformac ion("periodo") _
+ vbCrLf + "Grado: " & sGrado & " Grupo: " & sGrupo & " Materia: " &
sMateria.Replac e(" ", "").Replace("|" , " ") _
+ Chr(9) + ObtieneInformac ion("seccion") + vbCrLf + "Página {0} de {1}", _
Chr(9) + Chr(9) + _
"Profesor: " & ObtieneInformac ion("profesor") + vbCrLf + vbCrLf + vbCrLf +
"Firma: _______________ _______________ ___")
It works fine, but when printing in a certain printer it prints just strange
characters
I can use this printer from any application in Windows and it works fine
I've already tried to install the printer drivers, but it is still printing
wrong
What can I do?
Alejandra Parra
Mexico
' get grid's PrintDocument object
Dim pd As System.Drawing. Printing.PrintD ocument
pd = flexgrid.PrintP arameters.Print Document()
' set up the page (landscape, 1.5" left margin)
With pd.DefaultPageS ettings
..Landscape = False
..Margins.Left = 50
Dim a As New Printing.PaperS ize("Carta", 850, 1100)
..PaperSize = a
End With
' set up header and footer fonts
flexgrid.PrintP arameters.Heade rFont = New Font("Tahoma", 10, FontStyle.Bold)
flexgrid.PrintP arameters.Foote rFont = New Font("Tahoma", 10,
FontStyle.Regul ar)
' preview the grid
flexgrid.PrintG rid("Calificaci ones",
C1.Win.C1FlexGr id.PrintGridFla gs.FitToPageWid th +
C1.Win.C1FlexGr id.PrintGridFla gs.ShowPreviewD ialog, _
Now.ToString("d d/MM/yyyy") + vbCrLf + Now.ToString("H H:mm:ss") _
+ Chr(9) + ObtieneInformac ion("escuela") + vbCrLf + "Calificaci ones Periodo
" & ObtieneInformac ion("periodo") _
+ vbCrLf + "Grado: " & sGrado & " Grupo: " & sGrupo & " Materia: " &
sMateria.Replac e(" ", "").Replace("|" , " ") _
+ Chr(9) + ObtieneInformac ion("seccion") + vbCrLf + "Página {0} de {1}", _
Chr(9) + Chr(9) + _
"Profesor: " & ObtieneInformac ion("profesor") + vbCrLf + vbCrLf + vbCrLf +
"Firma: _______________ _______________ ___")
It works fine, but when printing in a certain printer it prints just strange
characters
I can use this printer from any application in Windows and it works fine
I've already tried to install the printer drivers, but it is still printing
wrong
What can I do?
Alejandra Parra
Mexico
Comment