Jurate,
This is what I would do. I would handle the mouse down and mouse up
events on the form. When the mouse is held down, I would set a flag
indicating that the mouse button is pressed down, and set it to false on the
mouse up event. Also, in the mouse down event, I would store the current
location of the mouse.
Then, I would add an event handler for the mouse move event. In that
event, if your flag is set, then I would get the current mouse location.
Compare it with the previous mouse location, finding the difference between
the two. Adjust the form's Location property by that difference and it will
move. The important thing is to also store the current location of the
mouse after all of this.
Hope this helps.