[RESOLVED] drag treeview nodes to picture boxes
Hello,
I need to drag a tv node to a pic box, I got this code:
Code:
Private Sub Inv_ItemDrag(sender As System.Object, e As System.Windows.Forms.ItemDragEventArgs) Handles Inv.ItemDrag
If e.Button = MouseButtons.Left Then
Inv.SelectedNode.Tag = PictureBox1.Image
DoDragDrop(e.Item, DragDropEffects.Copy)
End If
End Sub
Private Sub PictureBox2_DragDrop(sender As System.Object, e As System.Windows.Forms.DragEventArgs) Handles PictureBox2.DragDrop
AllowDrop = True
PictureBox2.Image = Inv.SelectedNode.Tag
End Sub
I want the picturebox2 image to change to picturebox1 image when a node is dropped there.
Re: drag treeview nodes to picture boxes
I already posted a working, adaptable project in your other thread: http://www.vbforums.com/showthread.php?t=670684
Re: drag treeview nodes to picture boxes
oh, I didn't see that. Thank you very much!