Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
3555
Dragging/Droping with Hierarchical parent/child relationship in Grid
posted
I have 2 grids:

Grid 1 has the following schema

DrugId, DrugName



Grid 2 is a hierarchical grid for the following schema

Band(0): GroupId, GroupName
Band(1): GroupId, DrugId, DrugName

Is it possible to allow the user to drag and drop those drugs from Grid 1
into Band(1) of grid 2, thus linking them to the Band(0) group? If so, how
would I go about doing this?

Thanks so much
Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

    Hi,

        Drag and Drop in DotNet are pretty flexible. You can certainly implement this, but there are quite a lot of variables here in terms of how you do it. What part of this is giving you trouble?

        You will need to start a drag on the first grid. So this involves using the right SelectTypeRow property setting and also probably handling the SelectionDrag event.

        On the destintation grid, you need to handle DragDrop and/or DragOver. You will need to determine which row was dropped on, so I recommend this KB article for that:  HOWTO:UltraWinGrid Mouse Position and Row Identification

Children