CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1

    Why does TreeView Control move when drag and drop?

    I do a drag and drop on a tree view and the control is moving when i drag the node. what property needs to be set to make the treeview stick to the form?

    also anyone have a good scrolling treeview drag and drop example?


  2. #2
    Join Date
    May 1999
    Location
    Oxford UK
    Posts
    1,459

    Re: Why does TreeView Control move when drag and drop?

    You need to supply the treeview with a drag icon, otherwise the whole control appears to be dragged. I'd recommend using OLE drag & drop - it's a lot 'nicer' to work with.

    >also anyone have a good scrolling treeview drag and drop example?

    Yep - take a look at the source-code for the VBCodeLibrary version 2 at http://codeguru.developer.com/vb/articles/1724.shtml

    The treeview control in the program scrolls on dragging/dropping and also uses a custom icon for the drag/drop process.




    Chris Eastwood

    CodeGuru - the website for developers
    http://codeguru.developer.com/vb

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured