Message 1 of 7
Drag drop from Tree or List removes the selected item?
Not applicable
02-08-2000
03:38 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
When I drag/drop from a list or tree (using OLESetData and OLEStartDrag)
and drag the file into AutoCAD to cause the "_Insert" command, the list
view (or tree) then removes that item from the list. I don't want the
item removed.
Is there a property set somewhere to prevent this? I tried all of the
effects, but nothing - in fact, some of the effects prevents the
"insert" command.
Here's my code:
//set the list or tree to ccOLEAutomatic
//listview is called "lstResults"
//selected file is called "file"
Private Sub lstResults_OLESetData(Data As MSComctlLib.DataObject,
DataFormat As Integer)
Data.Files.Add file
End Sub
Private Sub lstResults_OLEStartDrag(Data As MSComctlLib.DataObject,
AllowedEffects As Long)
Data.Clear
Data.SetData , vbCFFiles
End Sub
*thanks to Randall Rath for the code on this!
This will cause the "insert" command, but removes the list item.
Any ideas?
Thanks as always,
Colin Mitchell
TURCK Inc.
and drag the file into AutoCAD to cause the "_Insert" command, the list
view (or tree) then removes that item from the list. I don't want the
item removed.
Is there a property set somewhere to prevent this? I tried all of the
effects, but nothing - in fact, some of the effects prevents the
"insert" command.
Here's my code:
//set the list or tree to ccOLEAutomatic
//listview is called "lstResults"
//selected file is called "file"
Private Sub lstResults_OLESetData(Data As MSComctlLib.DataObject,
DataFormat As Integer)
Data.Files.Add file
End Sub
Private Sub lstResults_OLEStartDrag(Data As MSComctlLib.DataObject,
AllowedEffects As Long)
Data.Clear
Data.SetData , vbCFFiles
End Sub
*thanks to Randall Rath for the code on this!
This will cause the "insert" command, but removes the list item.
Any ideas?
Thanks as always,
Colin Mitchell
TURCK Inc.