Information générale
Catégorie:
Contrôles ActiveX en VFP
Titre:
Drag and drop operations
Maybe i put the message in the wrong section...:-)
Anyway, i start thinking about using a drag and drop solution in my programs.. What i want to do actually is to drag a voice from a grid (but i guess it's not possible, is it ?) or from a listbox into a Treeviecontrol.
I try to follow the example but i can't do anything.
What can I do ?
I tried to copy the example code in my object but for example i got an error when the program start processing the OleDragOver method in which I try to get the format of the object :
LPARAMETERS odataobject, effect, button, shift, x, y, state
DO CASE
CASE State == 0 &&DRAG_ENTER
DO CASE
CASE oDataObject.GetFormat("OLE Variant Array") && Array
This.OLEDropHasData = 1 &&DROPHASDATA_USEFUL
This.OLEDropEffects = 1+2 &&DROPEFFECT_COPY + DROPEFFECT_MOVE
CASE oDataObject.GetFormat(1) && Text
This.OLEDropHasData = 1 &&DROPHASDATA_USEFUL
This.OLEDropEffects = 1+2 &&DROPEFFECT_COPY + DROPEFFECT_MOVE
CASE oDataObject.GetFormat(15) && Files CF_HDROP
This.OLEDropHasData = 1 &&DROPHASDATA_USEFUL
This.OLEDropEffects = 4 &&DROPEFFECT_LINK
OTHERWISE
This.OLEDropHasData = 0 &&DROPHASDATA_NOTUSEFUL
ENDCASE
I don't know what this code mean...i was trying to understand :-)
Thank you again
Alessio
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement