Back to Devexpress

DataControlBase.CopyRangeToClipboard(Int32, Int32) Method

wpf-devexpress-dot-xpf-dot-grid-dot-datacontrolbase-dot-copyrangetoclipboard-x28-system-dot-int32-system-dot-int32-x29.md

latest2.6 KB
Original Source

DataControlBase.CopyRangeToClipboard(Int32, Int32) Method

Copies values displayed within the specified range of rows/cards to the clipboard.

Namespace : DevExpress.Xpf.Grid

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

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public void CopyRangeToClipboard(
    int startRowHandle,
    int endRowHandle
)
vb
Public Sub CopyRangeToClipboard(
    startRowHandle As Integer,
    endRowHandle As Integer
)

Parameters

NameTypeDescription
startRowHandleInt32

An integer value specifying the handle of the first row in the range.

| | endRowHandle | Int32 |

An integer value specifying the handle of the last row in the range.

|

Remarks

To copy the values displayed within selected rows, use the DataControlBase.CopySelectedItemsToClipboard method. To copy the values displayed within the specified rows/cards, use the DataControlBase.CopyRowsToClipboard method.

All of these methods do nothing if the DataControlBase.ClipboardCopyMode property is set to None.

csharp
gridControl1.CopyRangeToClipboard(gridControl1.GetRowHandleByVisibleIndex(0), gridControl1.GetRowHandleByVisibleIndex(gridControl1.VisibleRowCount - 1));

To learn more, see Clipboard Management.

See Also

CopyRowsToClipboard(IEnumerable<Int32>)

CopySelectedItemsToClipboard()

DataControlBase Class

DataControlBase Members

DevExpress.Xpf.Grid Namespace