Skip to main content

TreeList.ClipboardDataProvider Property

Gets an object that provides data for the clipboard in various formats (plain text, plain unicode text, rich text, CSV, BIFF8, HTML).

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v24.1.dll

NuGet Packages: DevExpress.Win.Navigation, DevExpress.Win.TreeList

Declaration

[DXCategory("Data")]
[Browsable(false)]
public virtual TreeListClipboardDataProvider ClipboardDataProvider { get; }

Property Value

Type Description
TreeListClipboardDataProvider

An object that provides data for the clipboard in various formats (plain text, plain unicode text, rich text, CSV, BIFF8, HTML).

Remarks

The ClipboardDataProvider property returns a TreeListClipboardDataProvider class instance. This object provides data for the clipboard in a variety of formats (plain text, rich text, plain unicode text, CSV, BIFF8, HTML). Use the provider’s methods to get data that is currently selected in the control and will be passed to the clipboard if the user presses Ctrl+C. For example, the TreeListClipboardDataProvider.GetTextData method returns data for the clipboard in the plain text format.

Example

The TreeListClipboardDataProvider allows you to get data that are currently selected in the tree list and will be passed to the clipboard. The figure and code below show the selected nodes in the control, usage of the TreeListClipboardDataProvider.GetCsvData method, and the returned value.

image

treeList1.ClipboardDataProvider.GetCsvData();

// The method returns the following value:
//
//Sales,,,Change From Prior Year,,Current Market Share 
//Region,March,September,March,September,Market Share
//Western Europe,30540,33000,-5.50%,-7.58%,70%
//Austria,22000,28000,-18.73%,-1.79%,92%
//Belgium,13000,9640,-11.54%,-16.18%,16%
See Also