Line on cursor direction

Hello guys,

          I need to know how to do the effect of a stroke following the mouse as a drag and drop within 2 listbox, type one effect it has in Dreamweaver to place links in texts, any help will be appreciated!

Thanks for any help.

To be clear, when I drop the item from the listbox 2 on the listbox 1 I will shoot an action.

Paulo, this is still not very clear. You want something like the red arrow to follow the mouse ? Is that it ?

Hi Michel, Yes I want to do drag and drop and while I do not release the mouse the “elastic” keep following the path of your cursor, this same mechanism has in some programs such as Dreamweaver for example, even in Objetive C to link an element with the other

Here is an example I did by modifying the drag and drop example :
ListBoxesDragAndDroparrow.xojo_binary_project

It uses a canvas overlaid over the window. In the canvas keydown, DragArrowStartX and DragArrowStartY are initialized as well as the boolean MouseButtonDown. In Timer1 System.MouseX and System.MouseY are monitored, DragArrowCurrentX and DragArrowCurrentY are set, and if the button is down, the canvas is invalidated. If the button is up, MouseButtonDown is turned to false. In the Canvas Paint, the line is drawn together with a little circle at the end. I did not feel like spending a lot of time figuring out an arrow head :wink:

[quote=225249:@Michel Bujardet]Here is an example I did by modifying the drag and drop example :
ListBoxesDragAndDroparrow.xojo_binary_project

It uses a canvas overlaid over the window. In the canvas keydown, DragArrowStartX and DragArrowStartY are initialized as well as the boolean MouseButtonDown. In Timer1 System.MouseX and System.MouseY are monitored, DragArrowCurrentX and DragArrowCurrentY are set, and if the button is down, the canvas is invalidated. If the button is up, MouseButtonDown is turned to false. In the Canvas Paint, the line is drawn together with a little circle at the end. I did not feel like spending a lot of time figuring out an arrow head ;)[/quote]

Michel Bujardet Have no words to thank more this kindness you did me, I thought someone would have some idea but you went further and sent me the finished project and without asking anything in return, it’s people like you who never stop believing in goodness human.
Say thank you is just your kindness to me, Thank you again my friend !