Home Forums WinForms controls Xceed Grid for WinForms Multi-select drag doesn’t work without hold Shift key

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #14554 |

    If multiple rows are selected, clicking just the left mouse button to drag them, reverts the selection to only 1 row. The workaround for this is to hold down shift and then begin drag, but that’s not intuitive. Is there a way to accomplish drag and drop of multiselected rows without having to hold down shift?

    Thanks in advance,
    Todd Berry

    Imported from legacy forums. Posted by tberry (had 3598 views)

    User (Old forums)
    Member
    Post count: 23064

    There is no built-in way of doing this. What can be done is to have the mouse select multiple rows without pressing the shift key, and then make the drag operation without releasing the mouse button. We have a <a href=”http://download3.xceedsoft.com/Archive/SelectedCells.zip”>sample</a&gt; that shows how to do it. It is cell based, but should be fairly easy to make it row based if you so wish.

    There could be a way to handle the SelectedRowsChanged, and if the user clicks within what was selected, then revert back the SelectedRows collection to what it was before the click. Then the drag operation would be for the whole selection. This, however, has not been tested.

    Imported from legacy forums. Posted by André (had 759 views)

    User (Old forums)
    Member
    Post count: 23064

    Do you that example is vb.net? I tried to convert it and it doesn’t seem to work.

    Imported from legacy forums. Posted by jspence3 (had 174 views)

    User (Old forums)
    Member
    Post count: 23064

    Sorry I meant do you have that example in vb.net? I tried to convert the sample code over to vb.net from C# and it doesnt seem to work.

    Imported from legacy forums. Posted by jspence3 (had 254 views)

    User (Old forums)
    Member
    Post count: 23064

    Here is the <a href=”http://download3.xceedsoft.com/Archive/SelectedCells VB.zip”> VB sample</a>. It has been converted by an automated tool, so the code may look awkward at times, but it compiles and runs fine, as the C# sample.

    Imported from legacy forums. Posted by André (had 4692 views)

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.