- Online Barcode Generator
- How To
- Buy Now
Information to ListBox Drag and Drop Feature
In the tutorial page Reorder feature of ListBox and Transfer feature of ListBox, we know that we can change the listbox item order by using the up or down button and that we can transfer items between listboxes using the transferring buttons.
And in this online tutorial, we aim to guide users to achieve the item reordering and transferring functions with an easy drag and drop action.
How to Enable Drag and Drop Function
In this section, we will offer developers with two methods for activating the drag and drop function within the ListBox Control. One is through programming code and the other is via client-side events.
Sample Programming Code for Activating Drag and Drop Function
PerListBoxSource.EnableDragAndDrop = true;
The EnableDragAndDrop property provided by the PerListBox control is designed to enable or disable the drag and drop function. If you set this property to true, then you can change the item order by dragging a listbox item to any desired location of the list and you can transfer items between listboxes by dragging one item from one listbox and drop it to another listbox on the condition that you allow the item reordering and transferring functions to be used.
Here we attach an image which shows the result of applying drag and drop function in the item transferring project.
Client-side Events for Activating Drag and Drop Function
Here we just simply mention the method to fire some drag and drop related events at client side.
Other ListBox Related Features
Apart from the drag and drop function, the PerListBox Control also offers other advanced item managing features, like
ASP.NET AJAX UI Controls