473,320 Members | 1,695 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Copy DataGrid Rows to Clipboard

How do I copy the contents of selected rows in a DataGrid (that is
bound to a Dataset via a DataView) to the Clipboard for pasting into
other applications - such as Excel? Doing the same from a TextBox is
easy via the TextBox.SelectedText property, but I can't find the
DataGrid property to do the same for the selected rows.

Mar 6 '06 #1
2 3102
Devlei,

I would not know why this would go. A datagrid is not an dataformat, so it
can not be used on the clipboard.

I assume that you will first have to make an excel sheet from it using the
office development or office interop.

I hope this helps,

Cor

"Devlei" <de****@eastcape.net> schreef in bericht
news:11**********************@i40g2000cwc.googlegr oups.com...
How do I copy the contents of selected rows in a DataGrid (that is
bound to a Dataset via a DataView) to the Clipboard for pasting into
other applications - such as Excel? Doing the same from a TextBox is
easy via the TextBox.SelectedText property, but I can't find the
DataGrid property to do the same for the selected rows.

Mar 6 '06 #2
Thanks Cor

How do I get a Collection of currently selected rows?

Dave

Mar 7 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Faith | last post by:
Hello. I need to take a column from Excel(unknown amount of rows) that will be selected by the user and copy those cells. Then I will need to paste those cells into the first column in a Data...
9
by: (Pete Cresswell) | last post by:
I see this coming on a develpment effort that may materialize shortly. These guys don't want to mess around with automated imports from text feeds BC in the past they've had too many problems...
0
by: JMWilton | last post by:
I am using the DataGrid in my application (windows not web). It appears that the DataGrid responds to a CTRL-C (copy) if one or more rows have been highlighted manually. There does not seem to be...
3
by: PeterZ | last post by:
Hi, In a running C# app with a datagrid control I select all rows in the dataGrid using CTRL-A, I then paste into some other app like notepad or Word but the column headings get left off. Is...
13
by: John | last post by:
Hi How can I implement cut or copy or paste in code? Thanks Regards
7
by: lgbjr | last post by:
Hello All, I¡¯m using a context menu associated with some pictureboxes to provide copy/paste functionality. Copying the image to the clipboard was easy. But pasting an image from the clipboard...
0
by: MKBender | last post by:
dear all, I have a dataGridView that has cut,copy, and paste functionality for the cells of the datagrid but now I would like to add the functionality for the user to copy, cut and paste an...
6
by: garyusenet | last post by:
Hi I would like to know if it's possible to copy just the collapsed view vissible from the IDE to the clipboard. If i have collapsed code, and then highlight it and copy it - and then paste this...
1
by: The Tarm | last post by:
Hi everyone, I found resources on the web to do a copy on a datagridview control but i havent found any on pasting back to the control. I m trying to figure out how to do a shallow copy on a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.