Trying to draw a simple line on a form and cannot figure out where I am going wrong. I have done this when I send a doc to print, but the same method isnt working.
I have a form with tabpages on it. On one of the tabpages I have a Picture Box where I want the line to be.
Dim PSNormal As New Pen(Black, 1)
Dim g As Graphics = Me.pb.CreateGraphics
g.DrawLine(PSNormal, 5, 50, TabPage5.Width - 5, 50)
Also, this is in a function in. Could that be the reason it is not working??
I can create a label on the fly and have it appear, just not the line.
Thanks
I have a form with tabpages on it. On one of the tabpages I have a Picture Box where I want the line to be.
Dim PSNormal As New Pen(Black, 1)
Dim g As Graphics = Me.pb.CreateGraphics
g.DrawLine(PSNormal, 5, 50, TabPage5.Width - 5, 50)
Also, this is in a function in. Could that be the reason it is not working??
I can create a label on the fly and have it appear, just not the line.
Thanks