Private Sub Command1_Click()
Dim oldcursor&
oldcursor = Screen.MousePointer
Screen.MousePointer = 11
Printer.Print " " ' Convince VB that something should be printed
PrintBitmap Picture1, Printer.hdc
Printer.NewPage
Printer.EndDoc
Screen.MousePointer = oldcursor
End Sub
Option Explicit
Private Declare Function SetPixel Lib "gdi32" (ByVal hdc As Long, ByVal x As Long, ByVal y As Long, ByVal crColor As Long) As Long
Private Sub Command1_Click()
Dim i As Long, j As Long
For i = 0 To Picture1.Width / 15
For j = 0 To Picture1.Height / 15
SetPixel Picture1.hdc, i, j, vbRed
Next j
Next i
For i = 0 To Picture1.Width / 15
SetPixel Picture1.hdc, i * i, i, vbBlack
Next i