Configuring Run-Time Drag-and-Drop Behavior for Text-Based Controls
- Updated2025-01-22
- 2 minute(s) read
Configuring Run-Time Drag-and-Drop Behavior for Text-Based Controls
To enable users to drag and drop data between text-based controls in a VI, such as string, path, listbox, multicolumn listbox, and tree controls, you must configure drag-and-drop behavior for those controls. You can configure the drag-and-drop behavior of text-based controls in the following ways:
- Allow dragging from the control during run time.
- Allow dropping in the control during run time.
- Select between moving and copying data from the control.
- Allow dropping in controls other than the control from which the drag originated.
- Allow dragging of parent items in tree controls.
- Allow items dropped in tree controls to drop as parent items.
Enable multiple drag-and-drop settings simultaneously to configure specific behavior for text-based controls. For example, to enable dragging from a listbox to a tree control, you must allow dragging on the listbox, allow data from the listbox to drop in controls other than the listbox, and allow dropping in the tree control.
Allow Dragging from the Control during Run Time
Control | Shortcut Menu Item | Property |
String | Advanced»Allow Dragging | String Properties: Allow Dragging |
Listbox | Drag and Drop»Allow Dragging | Listbox Properties: Drag/Drop:Allow Dragging |
Multicolumn Listbox | Drag and Drop»Item Dragging»Allow Dragging | Multicolumn Listbox Properties: Drag/Drop:Allow Dragging |
Tree | Drag and Drop»Allow Dragging | Tree Properties: Drag/Drop:Allow Dragging |
Allow Dropping in the Control during Run Time
Control | Shortcut Menu Item | Property |
String | Advanced»Allow Dropping | String Properties: Allow Dropping |
Path | Advanced»Allow Dropping | Path Properties: Allow Dropping |
Listbox | Drag and Drop»Allow Dropping | Listbox Properties: Drag/Drop:Allow Dropping |
Multicolumn Listbox | Drag and Drop»Allow Dropping | Multicolumn Listbox Properties: Drag/Drop:Allow Dropping |
Tree | Drag and Drop»Item Dragging»Allow Dropping | Tree Properties: Drag/Drop:Allow Dropping |
Select between Moving and Copying Data from the Control
Control | Shortcut Menu Item | Property |
Listbox |
|
Listbox Properties: Drag/Drop:Drag Mode |
Multicolumn Listbox |
|
Multicolumn Listbox Properties: Drag/Drop:Drag Mode |
Tree |
|
Tree Properties: Drag/Drop:Drag Mode |
Allow Dropping in Controls Other Than the Control from Which the Drag Originated
Control | Shortcut Menu Item | Property |
Listbox | Drag and Drop»Item Dragging»Allow Drag Drop Outside Control | Listbox Properties: Drag/Drop:Allow Drag and Drop Outside Control |
Multicolumn Listbox | Drag and Drop»Item Dragging»Allow Drag Drop Outside Control | Multicolumn Listbox Properties: Drag/Drop:Allow Drag and Drop Outside Control |
Tree | Drag and Drop»Item Dragging»Allow Drag Drop Outside Control | Tree Properties: Drag/Drop:Allow Drag and Drop Outside Control |
Allow Dragging of Parent Items in Tree Controls
Control | Shortcut Menu Item | Property |
Tree | Drag and Drop»Item Dragging»Allow Dragging of Parent Items | Tree Properties: Drag/Drop:Allow Dragging of Parent Items |
Allow Items Dropped in Tree Controls to Drop as Parent Items
Control | Shortcut Menu Item | Property |
Tree | Drag and Drop»Item Dropping»Allow Dropping Between Items | Tree Properties: Drag/Drop:Allow Dropping Between Items |
In This Section
- Allow Dragging from the Control during Run Time
- Allow Dropping in the Control during Run Time
- Select between Moving and Copying Data from the Control
- Allow Dropping in Controls Other Than the Control from Which the Drag Originated
- Allow Dragging of Parent Items in Tree Controls
- Allow Items Dropped in Tree Controls to Drop as Parent Items