Get System.drawing.pen Vb.net Background. This unfortunately enlarges my path: This is a simple freehand drawing example for vb.net.
Any suggestions on how to resolve this error ? If anybody understands what i want to do, i would be glad to get a reply! Imports system.drawing.graphics public class form1 private sub form1_paint(byval sender as object, byval e as system.windows.forms.painteventargs) handles mybase.paint ' create four pen objects with red, ' blue, green, and black colors and ' different widths dim redpen as new pen.
To draw on the form outside of the form1_paint, say a button click you can use system.drawing.graphics like this:
Dim pen as new system.drawing.pen(system.drawing.color.black, 10). Some of them are gradient brushes, pen caps system.drawing.printing. I have imports system.drawing and have tried several different imports statements but cannot resolve the error. Dim lastpoint as point dim thickblackpen as new pen(color.black, 4.0f) ' true while we are.