moving controls at run time
moving controls at run time
API Declarations
Dim x1, y1, z1, w1, t1, l1
Rate moving controls at run time
(1(1 Vote))
Private Sub Command1_DragDrop(Source As Control, X As Single, Y As Single)
If X > x1 Then
Command1.move l1 + X - x1, t1 + Y - y1, z1, w1
Else
Command1.move l1 - x1 + X, t1 - y1 + Y, z1, w1
End If
End Sub
Private Sub Command1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
z1 = Command1.Width
w1 = Command1.Height
t1 = Command1.top
l1 = Command1.Left
x1 = X
y1 = Y
Command1.Drag
End Sub
Private Sub Form_DragDrop(Source As Control, X As Single, Y As Single)
If X > x1 Then
Command1.move X - x1, Y - y1, z1, w1
Else
Command1.move x1 - X, y1 - Y, z1, w1
End If
End Sub
moving controls at run time Comments
No comments yet — be the first to post one!
Post a Comment