|
-
Oct 10th, 2000, 12:43 AM
#1
Thread Starter
Member
Hi,
I'm trying to copy information from VB6 to MS Excel which works fine until I wanted to copy information from a MSChart object. I have placed the information on the clipboard and if I manually past the information from within Excel it works just fine, but what syntax do I use to have the information past from within VB?
This is what I have used so far:
Set ExcelSheet = obExcelProg.Sheets(intSheetno)
'Display the graph's heading
ExcelSheet.Cells(1, 1).Value = lblGraphHeading.Caption
'Copy the Chart information
chGraph.EditCopy
'Paste the information into Excel
???????
I hope someone can help me out here,
Thank you!
-
Oct 10th, 2000, 12:57 AM
#2
Hyperactive Member
Hello jess,
I do think you need the clipboard function of VB.
Clipboard.Clear
Clipboard.GetData
Clipboard.GetFormat
Clipboard.GetText
Clipboard.SetData
Clipboard.SetText
Good luck.
Michelle.
-
Oct 10th, 2000, 01:29 AM
#3
Thread Starter
Member
Thanks for answering me, but I need more information.
I'm using:
chGraph.EditCopy
to copy the information to the clipboard
and I guess I need to use:
Clipboard.GetData()
to paste the data into Excel, but it is the syntax for that that I need.
I have tried things like:
'ExcelSheet.Cells(1, 1).Value = Clipboard.GetData()
'ExcelSheet.Range("A2:E19").Value = Clipboard.GetData()
But I cannot get it to work.
Hopy you Michelle or someone else can give me a hint of what I'm doing wrong.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|