[Gambas-user] Drag and Drop - howto
Benoît Minisini
g4mba5 at gmail.com
Wed Apr 18 12:09:25 CEST 2018
Le 18/04/2018 à 11:51, Rolf-Werner Eilert a écrit :
> Last year I started a project which could benefit from dragging elements
> from one GridView to another with the mouse.
>
> As I was still developing the deeper code, I didn't take the time to
> dive in this, and this year I would like to complete it. Just had a look
> at the old code parts, and still do not grasp how these Drag, MouseDrag
> etc. are meant to work together.
>
> Public Sub GridView1_MouseDrag()
>
> TextBox1.Text = GridView1.Row & "::" & GridView1.Column
>
> End
>
> This starts as expected, but then keeps going - even beyond the borders
> of GridView1. This makes it somewhat combersome if you need a start
> value to be handed over to the drop point. I only see a chance when
> setting a flag at its first call and saving the value(s) only once.
>
> Public Sub GridView1_Drop()
>
> TextBox1.Text = "Stop"
>
> End
>
> This one is never raised, neither when the mouse button is depressed
> whithin nor when without GridView1.
>
> Why are there events called Mouse-something and NOT Mouse-something?
>
> Maybe someone here can shed a light on this for me.
>
> Regards
> Rolf
>
Have you read the page about "Drag & Drop" on the wiki?
--
Benoît Minisini
More information about the User
mailing list