VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple c

by Vaggelis Lamprinoudis (1 Submission)
Category: Custom Controls/Forms/Menus
Compatability: Visual Basic 5.0
Difficulty: Unknown Difficulty
Originally Published: Sat 11th May 2002
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple code, without any complicated declarations

Rate Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple c



'That's all !!

Public xMeLeft, xMeTop

Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
xMeLeft = X - Me.Left: xMeTop = Y - Me.Top
End Sub

Private Sub Form_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.Move X - xMeLeft, Y - xMeTop
End Sub

Download this snippet    Add to My Saved Code

Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple c Comments

No comments have been posted about Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple c. Why not be the first to post a comment about Drag & Move any form with or without CaptionBar by dragging it form any place on form.Very simple c.

Post your comment

Subject:
Message:
0/1000 characters