You should draw the line in a Paint event handler, for example:
Private Sub Form1_Paint(sender As Object, e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint
Dim blackPen As New Pen(Color.Black, 3)
e.Graphics.DrawLine(blackPen, x1, y1, x2, y2)
blackPen.Dispose...