View Single Post
  #10   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Graham Mayor Graham Mayor is offline
external usenet poster
 
Posts: 19,312
Default Merge Excel to Word field extension

See also - You receive the "Opening this will run the following SQL
command" message when you open a Word mail merge main document that is
linked to a data source - http://support.microsoft.com/?kbid=825765

--

Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org


EmilyR wrote:
We are typing data into the excel spreadsheet, each item has 1 row to
fit all the information.
Once we have the info we need in Excel, we go through our files, open
the word document, which has a pop up saying that
"Opening this document will run the following SQL command"
"Select * from 'STOCK$' "
"Data from your database will be placed in the document. Do you want
to continue?" Clcik yes, then select the Excel sheet we want it to
link to. The document then opens with the template, and we create the
mail merge. Tools, Mail Merge, edit recipient list, then tick the
box next to the item that it relates to.

Then when it's loaded the information we can see that 1 area only
brings over 255 characters from the cell.
In excel, sheet 1, so far we've used 321 rows for our items, and
using up to column 'BF'. The column that isn't coming through
properly is 'Z', so we do have a lot of data in there.

I hope this explains what we are trying to do???!!!!
I'll have a look at those links you've provided now and see how i
go.. will be in touch

"Peter Jamieson" wrote:

So are you
a. typing data into a 1 row Excel sheet, then merging that into a
Word document, then doing another row, or
b. typing multiple rows of data into an Excel sheet, then doing as
many merges as you have rows in the sheet, or
c. typing multiple rows into an Excel sheet, then doing one merge,
then splitting the output, or
d. what?

If you are typing multiple rows into an Excel sheet and you want to
produce 1 document per record, your best bet is probably either to
a. do the merge, then split the output (see
http://www.gmayor.com/individual_merge_letters.htm ) or
b. use a VBA macro to do one merge per record. (I suspect in this
case (a) wpould give you everything you need but I can provide macro
code for (b), or you can search for it in this group (e.g. look for
jamieson activerecord)

If you have only one -row spreadsheets as data sources, it surprises
me that you are only getting 255 characters through. I'd need to
check again what happens in that case. If you have multiple rows but
all the first 8 have fewer than 255 characters in the column in
question, you would see the rest of the rows truncate to 255
characters - all you /should/ need to do in that case is introduce a
dummy row someehere in the first 8 rows with more than 255
characters.

However, even if you cna't get the Excel data source to work, it
really should be quite easy to copy the entire data source into Word
by selecting the sheet, Edit|Copy, open a new Word document,
Edit|Past. You don't have to do a line by line copy. (Of course this
is no use if you are creting one-row spreadsheets).

I've also been told that the boss doesn't want
to seperate the information into 2 columns, which makes it even
harder.


Sorry, can't deal with that sort of stuff from here...


--
Peter Jamieson
http://tips.pjmsn.me.uk

"EmilyR" wrote in message
...
I'll have to look into the DDE bit,
the work we are doing is typing info into an excel spreadsheet, then
merging
it over to Word, each line in a separate document, and then each
document is
being downloaded onto our website.
Which with the amt of rows in each spreadsheet, it would be too
difficult to
copy and paste all of them. I've also been told that the boss
doesn't want
to seperate the information into 2 columns, which makes it even
harder.

Thnaks very much

"Peter Jamieson" wrote:

1. Is it stopping at 255 using DDE?

2. (I'm assuming that you have the space on the label to fit those
255 characters :-) )

3. Are you in a position to decide what mail merge data source you
start with? If you only have a small number of columns in Excel
(less than around
64) you should be able to copy/paste your Excel data into a new
Word document and use that as the data source.

I'm not sure if this sort of thing will work, as we are merging
sheet 1 &
2
seperately but with the intention of sorta doin the same thing.

Why does doing two merges make a difference?
--
Peter Jamieson
http://tips.pjmsn.me.uk

"EmilyR" wrote in message
...
thanks Peter,
I'm not sure if this sort of thing will work, as we are merging
sheet 1 &
2
seperately but with the intention of sorta doin the same thing.
I've figured out that the cell information stops at 255
characters when converted int Word. I somehow need to extend
this amount if possible, unfortunately theahrsh reality looks
like I can't do that and will need to
split the cells. Only problems there is there is so much data in
the column
that this is a problem with, it doesn't seem viable.

Any ideas??

"Peter Jamieson" wrote:

See http://tips.pjmsn.me.uk/t0003.htm

You probably need to try the "DDE" method mentioned near the top.

--
Peter Jamieson
http://tips.pjmsn.me.uk

"EmilyR" wrote in message
...
I've had a problem with mail merging data from Excel into Word.
It'll
take
over some of the data but can leave part of the information
off. I have
just
come to the conclusion that this is because it will only take
255 characters
from a particular Excel cell to Word.
Can anyone help in either extending the amount of characters or
some other
way to fix it??

Thanks in advance
Emily