Dim x1 As Integer Dim x2 As Integer Dim y1 As Integer Dim y2 As Integer x1 = Command1.Left + Command1.Width / 2 y1 = Command1.Top + Command1.Height / 2 x2 = Command2.Left + Command2.Width / 2 y2 = Command2.Top + Command2.Height / 2 Form1.Line (x1, y1)-(x2, y2), vbRed