Pasting from table to graph datasheet formatting

D

David Cuthill

I have a word macro that was originally created using Word
2000. The macro looks for a specific table within the
document copies the content, generates a chart using
MSGraph and then pastes the contents of the copied table
into the chart's datasheet. In the word 2000 version
everything worked fine.

I have now upgraded to Word XP and the paste ends up
pasting the tables data in the datasheet unformatted - ie.
rather than maintain the column and row formating from the
table the data is pasted free flowing in the first column
of the datasheet.

example ...

date
quantity
11/12/2003
12

rather than ...

date quantity
11/12/2003 12


Has anyone else seen this behaviour and do you have an
suggestions on remedying it. If I do the copy paste
manually it works fine.
 
C

Cindy Meister -WordMVP-

Hi David,
Okay, so it looks like no one else has experienced
something similar to this.
No, I can't recall having ever seen this...

Rather than copy/paste (which is always tricky), why not
read the data from the table and insert it into the data
sheet?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update
Jan 24 2003)
http://www.mvps.org/word

This reply is posted in the Newsgroup; please post any
follow question or reply in the newsgroup and not by e-mail
:)
 
C

Cindy Meister -WordMVP-

Hi David,
I am not clear on what you are meaning by read the table and then
insert it into the data sheet.
I mean loop through it, cell by cell, and write the values for each
cell into the corresponding cell on MS Graph's datasheet. Have you
ever automated an Excel spreadsheet?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jan 24
2003)
http://www.mvps.org/word

This reply is posted in the Newsgroup; please post any follow
question or reply in the newsgroup and not by e-mail :)
 
D

David Cuthill

Thanks Cindy ... I am familiar with automating a spreadsheet. I will
try to apply some of this to the datasheet for graph.

David
 
C

Cindy Meister -WordMVP-

Hi David,
am familiar with automating a spreadsheet. I will
try to apply some of this to the datasheet for graph.
OK, that's good :) It works basically the same, but the
first row/column have, as I recall, an index of 0 (instead
of 1 / A as in Excel).

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update
Jan 24 2003)
http://www.mvps.org/word

This reply is posted in the Newsgroup; please post any
follow question or reply in the newsgroup and not by e-mail
:)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top