Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Drag and drop from a list box
Message
From
24/06/1999 09:56:46
 
 
To
23/06/1999 17:13:35
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00232678
Message ID:
00233475
Views:
35
Dragicon is what I was looking for, thanks man! Is the following "paradigm" pretty much the standard way of allowing multiple (.multiselect = .t.) listitems from a listbox and dropping them into another listbox?

1. list1.multiselect = .t.
2. list1.mousedown event starts dragging
3. list2.dragdrop event scans list1 for the items selected and uses them to populate an array.
4. list2.requery is called

Good? Bad? Is there a better way?

>If you want to change the look of the icon used for dragging, you can use a different ico file specified with DragIcon. I'm not sure what you mean by define a custom cursor.
>
>>That would work. But it still drags the outline of the entire list box into the new list box. Do I need to define a custom cursor?
>>
>>>>I would like to be able to drag a listitem from a list box and drop it into another listbox. My problem is that the drag and drop stuff looks like it wants to affect the entire listbox, not just the list item. How can I just drag just the selected item(s) from the source listbox?
>>>
>>>You use the object reference that the Drop operation gives you to get to the source list's ListIndex or Value property,
>>>
>>>LPARAMETERS oSource, nXCoord, nYCoord
>>>THIS.AddItem(oSource.Value)
--Todd Sherman
-Wake Up! Smell the Coffee!
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform