Back to Devexpress

TreeViewControl.DragDropHintTemplate Property

wpf-devexpress-dot-xpf-dot-grid-dot-treeviewcontrol-9c5e4e9d.md

latest2.2 KB
Original Source

TreeViewControl.DragDropHintTemplate Property

Gets or sets the template that defines the drag-and-drop hint’s appearance. This is a dependency property.

Namespace : DevExpress.Xpf.Grid

Assembly : DevExpress.Xpf.Grid.v25.2.dll

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public DataTemplate DragDropHintTemplate { get; set; }
vb
Public Property DragDropHintTemplate As DataTemplate

Property Value

TypeDescription
DataTemplate

The template that defines the drag-and-drop hint’s appearance.

|

Remarks

The following code sample uses the ListBoxEdit control to show names of dragged records in the drag-and-drop hint:

xaml
<Window ...
        xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid" 
        xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors">
  <dxg:TreeViewControl ...
                       TreeViewFieldName="Name" 
                       SelectionMode="Row"
                       AllowDragDrop="True">
      <dxg:TreeViewControl.DragDropHintTemplate>
          <DataTemplate>
              <dxe:ListBoxEdit ItemsSource="{Binding Records}" 
                               DisplayMember="Name"/>
          </DataTemplate>
      </dxg:TreeViewControl.DragDropHintTemplate>
  </dxg:TreeViewControl>
</Window>

For information about drag-and-drop operations, refer to the following DevExpress WPF Grid help topic: Drag-and-Drop.

See Also

TreeViewControl Class

TreeViewControl Members

DevExpress.Xpf.Grid Namespace