[Gambas-user] Drag and Drop - howto

Rolf-Werner Eilert rwe-sse at osnanet.de
Wed Apr 18 18:39:53 CEST 2018


Am 18.04.2018 um 13:55 schrieb Christof Thalhofer:
> Am 18.04.2018 um 12:43 schrieb Rolf-Werner Eilert:
> 
>>> Have you read the page about "Drag & Drop" on the wiki?
>>>
>>
>> Nope, is there? I never found one. At least I cannot remember... ;)
> 
> http://gambaswiki.org/wiki/doc/dragndrop
> 
> 
> Alles Gute
> 
> Christof Thalhofer
> 

Danke!

This runs perfectly:

Public Sub GridView6_MouseDrag()

   GridView6.Drag(GridView6.Row & "::" & GridView6.Column)

End



Public Sub GridView1_Drop()

   TextBox1.Text = Drag.Data & "::" & Drag.Source.Name

End

And this is about everything I need here.

Maybe we should add such a little example to the documentation, and a 
link from the help texts?

I have question: In GridView6_MouseDrag() I have to give the name of the 
control. If I use a wrong one, the whole thing runs nevertheless:

Public Sub GridView6_MouseDrag()

   GridView1.Drag(GridView6.Row & "::" & GridView6.Column)

End

Is there a special case where I could benefit from this behaviour?

Regards
Rolf


More information about the User mailing list