Get the Node for the Drag/Drop Operation in the Treeview 
Author Message
 Get the Node for the Drag/Drop Operation in the Treeview

How can i get the correct Node Object for the Drag Operation in the
Treeview?
The following Code give the "last" SelectedItem, and not the correct Node.

Private Sub TreeView1_MouseDown(Button As Integer, Shift As Integer, x As
Single, y As Single)
         Set DragKnoten = TreeView1.SelectedItem      ' Legt den letzten
Knoten fest
         Set TreeView1.DropHighlight = Nothing
end sub

TIA
Udo



Wed, 20 Nov 2002 03:00:00 GMT  
 Get the Node for the Drag/Drop Operation in the Treeview
I have found the answer itself. She sounds:  HitTest(x,y)

correct Code:

Private Sub TreeView1_MouseDown(Button As Integer, Shift As Integer, x As
Single, y As Single)
      Set DragKnoten = TreeView1.HitTest(x, y)
End Sub

Thanks
Udo



Thu, 21 Nov 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Expand a Treeview node during drag operation

2. Scroll the TreeView When Dragging and Dropping a Node

3. drag-dropping a treeview node onto a datagrid

4. Drag & Drop of TreeView Node

5. Help w/TreeView Node Drag and Drop

6. Treeview drag drop, node selected

7. how can I drag and drop treeview nodes between two instances of a single tree control

8. TreeView Node Drag/Drop and Scrolling

9. TreeView Control: Moving Nodes with Drag and Drop

10. how can I drag and drop treeview nodes between two instances of a single tree control

11. Treeview - Drag/Drop nodes

12. Treeview - Drag/Drop Nodes

 

 
Powered by phpBB® Forum Software