We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Copy Selected Rows to Clipboard

Thread ID:

Created:

Updated:

Platform:

Replies:

20353 Oct 14,2004 05:39 PM UTC Oct 15,2004 07:01 PM UTC WinForms 2
loading
Tags: GridControl
Jeff Lancaster
Asked On October 14, 2004 05:39 PM UTC

I am using the following code to copy the data from the selected range of cells into the clipboard: Dim range As GridRangeInfo = m_Grid.Model.SelectedRanges(0) Dim rangeList As GridRangeInfoList = New GridRangeInfoList rangeList.Add(range) m_Grid.Model.CutPaste.CopyTextToClipboard(rangeList) This works fine if my selected range only contains partial rows (ie: range.info ="R2C3:R3C4"). However, if I select my range by rows such that range.info ends up containing something like "R4:R5" the copy doesn''t seem to work. How can I modify this to recognize both range selections and entire row selections?

Administrator [Syncfusion]
Replied On October 14, 2004 06:15 PM UTC

Before adding your range to the rangelist, use range.ExpandRange to change an arbitrary range into a cell range. range = range.ExpandRange(1, 1, grid.Model.RowCount, grid.Model.ColCount)

Jeff Lancaster
Replied On October 15, 2004 07:01 PM UTC

That works great! Thanks, Clay.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;