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.
Unfortunately, activation email could not send to your email. Please try again.

Copy/Paste row headers and column headers

Thread ID:

Created:

Updated:

Platform:

Replies:

20759 Oct 25,2004 08:30 AM Mar 14,2006 06:14 AM Windows Forms 3
loading
Tags: GridControl
Desis Machino
Asked On October 25, 2004 08:30 AM

I have a grid with may columns and rows including a Row Header and a Column Header. However, when I select mutilple cells, including row and col headers and perform a copy then paste into a text file, all the text of the selected cells are pasted except for the row and column headers. Is there a way for me to allow copy/pasting of the the headers as well.

Administrator [Syncfusion]
Replied On October 25, 2004 10:55 AM

Try setting these flags in the ClipboardFlags property. this.gridDataBoundGrid1.Model.CutPaste.ClipboardFlags |= GridDragDropFlags.ColHeader | GridDragDropFlags.RowHeader;

Ketan Parekh
Replied On March 13, 2006 02:16 PM

Is there a way to paste column headers when they are not selected. What I mean is, if I select rows 1,3,5 in columns 2,3, and 5 I want headers of only those columns to be pasted. Thanks. >Try setting these flags in the ClipboardFlags property. > > >this.gridDataBoundGrid1.Model.CutPaste.ClipboardFlags |= GridDragDropFlags.ColHeader | GridDragDropFlags.RowHeader; >

Administrator [Syncfusion]
Replied On March 14, 2006 06:14 AM

Hi Ketan, The following code snippet, explains the way to include the respective column headers while copy and paste. private void Model_ClipboardCopy(object sender, GridCutPasteEventArgs e) { e.ClipboardFlags |= GridDragDropFlags.ColHeader; for(int i =0; i< this.gridDataBoundGrid1.Model.ColCount; i++) { if(e.RangeList.AnyRangeIntersects(GridRangeInfo.Col(i))) { e.RangeList.Add(GridRangeInfo.Cell(0,i)); } } } Let us know if this helps. Best regards, Madhan.

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.

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.

;