Stampa - Stampare con Printer.Print






Private Sub Command1_Click()
On Error GoTo Errore
Printer.CurrentX = 0
Printer.CurrentY = 0
Dim X, Y

Do
Printer.Print "Vaffanculo Y = " & Printer.CurrentY & " X = " & Printer.CurrentX
If Printer.CurrentY >= 400 Then
Exit Do
End If
Loop

Do
Printer.Print "Vaffanculo 2Y = " & Printer.CurrentY & " 2X = " & Printer.CurrentX
If Printer.CurrentY >= 9400 Then
Exit Do
End If
Loop

'riporta la scrittura a linea 0

Printer.CurrentY = 0
Do
' scrive a colonna (19)

Printer.CurrentX = Printer.TextWidth(Replicate("M", 19))

Printer.Print "Vaffanculo Y = " & Printer.CurrentY & " X = " & Printer.CurrentX
If Printer.CurrentY >= 400 Then
Exit Do
End If
Loop

Do

Printer.CurrentX = Printer.TextWidth(Replicate("M", 19))
Printer.Print "Vaffanculo 2Y = " & Printer.CurrentY & " 2X = " & Printer.CurrentX
If Printer.CurrentY >= 9400 Then
Exit Do
End If
Loop



Printer.EndDoc
Errore:

End Sub










( stampastampareconprinterprint.html )- by Paolo Puglisi - Modifica del 17/12/2023