tags:

views:

245

answers:

2

Hi,
I would like to allow my users to drag a couple of interface items around. At the moment, only seem able to draw directly to a graphics object using the Cursor.Draw method. I'd like to be able to show items being dragged around the screen, in the fashion of dragging Windows icons such as folders, which can be dragged from window to window and over the taskbar, and such. Does the dotnet framework provide the ability to do this, or would it require lots of hooking into scary Windows API functions?

EDIT: I want, while I am dragging stuff, to be able to see an image of the thing that I am dragging displayed next to the mouse cursor. I want to be able to drag the item outside of the window, and to continue to display it next to the mouse cursor.

A: 

We have a simialr question in SO. Move a picture box with Mouse . You can use the same thing (?) . keep your icons in the picture box and let the users move it.

Shoban
+1  A: 

I wonder if this may be of use: Drag and Drop in Windows Forms - A Primer

Lazarus