Printing lines and/or circles ignores your Printer.DrawWidth setting,
producing thin lines with the default DrawWidth of 1 instead of the thicker
lines desired.
Microsoft has confirmed this to be a bug in the Microsoft products
listed at the beginning of this article. We are researching this
bug and will post new information here in the Microsoft Knowledge
Base as it becomes available.
Open a New Standard EXE Project. Form1 is created by default.
Insert the following code into the Form's module:
Private Sub Form_Click()
'Printer.Print ' may work
'Printer.DrawWidth = 1 ' To make sure Null Circle is not visible
'Printer.Circle (0, 0), 0 ' Print Null Circle
Printer.DrawWidth = 50
Printer.Line (200, 500)-(Printer.ScaleWidth - 300, 1500), , B
Printer.Circle (Printer.ScaleWidth \ 2, Printer.ScaleHeight \ 2), _
Printer.ScaleWidth \ 3
Printer.Line (200, 2500)-(Printer.ScaleWidth - 300, 2500)
Printer.Line (200, Printer.ScaleHeight - 1200)- _
(Printer.ScaleWidth - 300, Printer.ScaleHeight - 200), , B
Printer.EndDoc
End Sub
Run the Project and click on the Form. Your printout will have a
horizontal box across the top of the page, followed by a horizontal
line, a large circle, and finally, a horizontal box across the bottom of
the page. Note that at least the first box will be in thin lines
rather than the thick lines expected for a DrawWidth of 50, indicating
that the DrawWidth setting was ignored for the Printer object.
Stop the Project.
Uncomment the Printer.Print line and repeat step 3. The printout may now
be the same or it may be correct with all objects drawn with a DrawWidth
of 50.
Stop the Project.
Comment out the Printer.Print line and uncomment the next two lines to
draw the Null circle, and then repeat step 3. Note that the lines and
circle are now printed with thick lines as desired.