Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Mailmerge and Fax / May 2006

Tip: Looking for answers? Try searching our database.

Merging Word with a mutiple sheets Excel file

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Guido Rossi - 04 May 2006 19:24 GMT
Is there anyone could help me doing this:

I have a word file and I want to merge it with a 4 sheets excel file; I'd
like word to ask me to which sheet connect while opening the mail merge
file.

Sheets are all in the same format.

Thank you
Guido
Peter Jamieson - 05 May 2006 09:01 GMT
If it's Word 2002/2003, you should get a choice of sheets by default when
you set up the connection to the workbook. That's obviously not quite the
same as "when you open the mail merge file", but all you have to do is go
through the connection process again. You will lose any sorts/filters you
set up.

To automate reconnection you would need to create a VBA module in your
document. For Word 2002/2003 it can be roughly as follows:

Sub AutoOpen()

Dim strDataSourcePathName

' Substitute the pathname you need here
strDataSourcePathName = "c:\mydata\myworkbook.xls"

' Make sure the previous data source is disconnected
ActiveDocument.MailMerge.MainDocumentType = wdNotAMergeDocument
' substitute the merge type you need here
ActiveDocument.MailMerge.MainDocumentType = wdFormLetters
' Open the data source - in this case, you should only need the path name of
the .xls
ActiveDocument.MailMerge.OpenDataSource _
 Name:=strDataSourcePathName

End Sub

If it's Word 2000/97, things are more difficult because the default
connection method (DDE) does not let you choose a sheet, and the ODBC method
forces you to check various options in its dialog before you can choose a
sheet. Manually, it might be best to reconnect using the "Excel Converter".
Worse, using code you can probably only connect to ODBC data and I am fairly
sure that you have to specify the sheet name - you cnanot leave it up to the
user to choose.

Peter Jamieson
> Is there anyone could help me doing this:
>
[quoted text clipped - 6 lines]
> Thank you
> Guido
ElleEm - 12 May 2006 23:23 GMT
Peter,
I am having a similiar problem that changing the options and following the
directions you mention in your previous reply this thread doesn't seem to
help. My new computer came with Office Pro 2003.

It seems that when trying to set up connection between the word doc and the
xls file, it's dividng up my xls file into several html files.  None of the
names match the sheets in the workbook. I can't make it let me choose the
sheet I need for anything. And it's ruining the original xls file in the
process. I open it up independently and all the data is completely gone,
apparently moved to html files in another folder?This is insane.   I've had
to retrieve it from a back up several times now and it's getting old real
fast. Doesn't seem to matter how I try to connect them, through the wizard,
the tool bar, whatever.

I used mail merge with word and excel 2000 quite a bit and I never ran into
anything even close to this.  I just want to have the merge fields show up in
a word doc from a particular worksheet within the file., no complicated
filtering or anything like that. It's very likely I am clueless and missing
some obvious change between the old and new,  but that doesn't help me  be
any less frustrated. Any ideas?

And you say we have to do some VBA coding to just keep the files connected
with each other now, which Word 97 and 2000 seemed to do on their own with
appararently no problem? That's not what I'd call very user friendly. Please
tell me your kidding.  

Mail merging was the only reason I even got Office on this new computer, but
if I have to  dig up my old office 2000 and install it just to have basic
mail merge, I'm sure you'll see the mushroom cloud from where ever your are
as my head implodes, hehehe.

-LM

> If it's Word 2002/2003, you should get a choice of sheets by default when
> you set up the connection to the workbook. That's obviously not quite the
[quoted text clipped - 42 lines]
> > Thank you
> > Guido
Doug Robbins - Word MVP - 13 May 2006 05:55 GMT
You are obviously doing something different to what thousands of other
people are doing.  Try using the original 3-Step Mail Merge Helper which you
can get access to by selecting Customize from the Tools menu and on the
Commands tab, select the All Commands category and then scroll down through
the list of Commands until you come to the Mail Merge Helper item and then
left click on it and drag it onto a toolbar or the expanded Tools menu.

There is also a Mail Merge Toolbar that can be activated by selecting
Toolbars from the View menu and then checking the Mail Merge item.

Forget what Peter said about VBA, that was for circumstances that are
different from yours.

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

> Peter,
> I am having a similiar problem that changing the options and following the
[quoted text clipped - 92 lines]
>> > Thank you
>> > Guido
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.