vb.net中 点击按钮时 触发窗体paint事件
如题PrivateSubLabel3_Paint(senderAsObject,eAsPaintEventArgs)HandlesLabel3.PaintDimpen1A...
如题
Private Sub Label3_Paint(sender As Object, e As PaintEventArgs) Handles Label3.Paint
Dim pen1 As New Pen(Brushes.DeepSkyBlue, 2)
e.Graphics.DrawLine(pen1, 0, 0, 0, Label3.Height)
e.Graphics.DrawLine(pen1, 0, 0, Label3.Width, 0)
e.Graphics.DrawLine(pen1, Label3.Width, 0, Label3.Width - 1, Label3.Height)
e.Graphics.DrawLine(pen1, 0, Label3.Height, Label3.Width, Label3.Height - 1)
pen1.Dispose()
End Sub 展开
Private Sub Label3_Paint(sender As Object, e As PaintEventArgs) Handles Label3.Paint
Dim pen1 As New Pen(Brushes.DeepSkyBlue, 2)
e.Graphics.DrawLine(pen1, 0, 0, 0, Label3.Height)
e.Graphics.DrawLine(pen1, 0, 0, Label3.Width, 0)
e.Graphics.DrawLine(pen1, Label3.Width, 0, Label3.Width - 1, Label3.Height)
e.Graphics.DrawLine(pen1, 0, Label3.Height, Label3.Width, Label3.Height - 1)
pen1.Dispose()
End Sub 展开
3个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询