'Picture box is the the same situtation.
[code]
'Allowing a form control to be movable (DRAG AND DROP)
'...ie drag label1
Option Explicit
Public globalX As Integer
Public globalY As Integer
Private Sub Form_DragDrop(Source As Control, X As _
Single, Y As Single)
Label1.Move X - globalX, Y - globalY
End Sub
Private Sub Label1_MouseDown(Button As Integer, _
Shift As Integer, X As Single, Y As Single)
Label1.Drag vbBeginDrag
globalX = X
globalY = Y
End Sub
[code]




Reply With Quote