Quantcast
Channel: Telerik Forums RSS
Viewing all articles
Browse latest Browse all 94857

RadListBox Drag and Drop without removing "dropped" item

$
0
0
Hi,

In order to achieve the desired functionality for RadListBox's DragDropBehavior you need to customize the default one. Please, check the following article from our help documentation that provides more detailed information how to implement a custom ListBoxDragDropBehavior:
http://docs.telerik.com/devtools/wpf/controls/dragdropmanager/behaviors/listboxdragdropbehavior

For you concrete scenario in order to prevent the items from removing as soon as they get dragged and dropped you need to override the base DragDropCompleted method - the base implementation of the method removes the items from the collection.
public class MyListBoxDragDropBehavior : ListBoxDragDropBehavior
{
    public override void DragDropCompleted(DragDropState state)
    {
        //implement some custom logic here
        //Do not call -> base.DragDropCompleted(state);
    }
}

Hopes this helps.

Regards,
Nasko
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 

Viewing all articles
Browse latest Browse all 94857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>