Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. DragDrop reorder nodes

DragDrop reorder nodes

Scheduled Pinned Locked Moved C#
announcement
3 Posts 2 Posters 8 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Ryan Cromwell
    wrote on last edited by
    #1

    I am looking for an intuitive way to allow users to reorder a treeview by dragging and dropping, though they can already drop on other nodes and update the hierarchy. So dropping on an item and inserting it before is not really an option. I currently have it such that when you dragover and right click you get a context menu that lets you insert before, but i'd like somehow to figure out when i'm inbetween two nodes. Anyone have any ideas. Tanka

    S 1 Reply Last reply
    0
    • R Ryan Cromwell

      I am looking for an intuitive way to allow users to reorder a treeview by dragging and dropping, though they can already drop on other nodes and update the hierarchy. So dropping on an item and inserting it before is not really an option. I currently have it such that when you dragover and right click you get a context menu that lets you insert before, but i'd like somehow to figure out when i'm inbetween two nodes. Anyone have any ideas. Tanka

      S Offline
      S Offline
      Stephane Rodriguez
      wrote on last edited by
      #2

      I am afraid the treectrl we know is not designed for rearrangement. What I would see is, when drag has begun, the treectrl folds and unfolds itself according to the mouse position, add space between items then show a xor drawn item (or set of items) to preview what the treectrl would look like with this item dropped here. This requires work, but this would give you a lot of audience:cool: and attention...:cool:


      MS quote (http://www.microsoft.com/ddk) : As of September 30, 2002, the Microsoft® Windows® 2000 DDK, the Microsoft Windows 98 DDK, and the Microsoft Windows NT® 4.0 DDK will no longer be available for purchase or download on this site. Support for development will ship at the same time as the Windows XP Service Pack 1 (SP1) release.

      R 1 Reply Last reply
      0
      • S Stephane Rodriguez

        I am afraid the treectrl we know is not designed for rearrangement. What I would see is, when drag has begun, the treectrl folds and unfolds itself according to the mouse position, add space between items then show a xor drawn item (or set of items) to preview what the treectrl would look like with this item dropped here. This requires work, but this would give you a lot of audience:cool: and attention...:cool:


        MS quote (http://www.microsoft.com/ddk) : As of September 30, 2002, the Microsoft® Windows® 2000 DDK, the Microsoft Windows 98 DDK, and the Microsoft Windows NT® 4.0 DDK will no longer be available for purchase or download on this site. Support for development will ship at the same time as the Windows XP Service Pack 1 (SP1) release.

        R Offline
        R Offline
        Ryan Cromwell
        wrote on last edited by
        #3

        I'll do what I can. I'm looking for quite a bit more in a Tree control (ie multiple checkboxes) so I may have some fun later on. Thanks though

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups