PC Review


Reply
Thread Tools Rate Thread

Access 2003 mail merge fails to recognise a mail merge document.

 
 
ColinD
Guest
Posts: n/a
 
      18th Mar 2008
I am trying to merge a single record in an Access table into a Word document.
I have set the data source in the Word document, and when I open it, it
correctly displays the record from Access.

However, I would like to be able to open the document programmatically from
within Access, with this code:

Set wrdDoc = wrdApp.Documents.Open("doc name", , True)
wrdDoc.MailMerge.Execute

But the Execute property generates the error:
This method or property is not available because the document is not a mail
merge main document.
The document opens but does not display the right record.

Any help would be appreciated.
Many thanks
Colin Dimond

 
Reply With Quote
 
 
 
 
Albert D. Kallal
Guest
Posts: n/a
 
      18th Mar 2008
I have a nice working sample that does a merge of the current record to
word.

The sample I have can be found here:
http://www.members.shaw.ca/AlbertKal.../msaccess.html

What is nice/interesting about my sample is that is specially designed to
enable ANY form with ONE LINE of code....

Thus, each time you build a new form, you can word merge enable it with
great ease.

Make sure you read the instructions from above, and you should eventually
get to the follwoing page
http://www.members.shaw.ca/AlbertKal...rge/page2.html


Note that the merge can also use a query, and thus you don't have to merge
just "one" record..

After the merge occurs, you get a plain document WITHOUT any merge fields,
and this allows the end user to save, edit, or even email the document
(since the merge fields are gone after the merge occurs).

Give the above a try.


--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
(E-Mail Removed)


 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mail Merge document with Linked Documents containing merge fields sylvana.bugeja@vicsuper.com.au Microsoft Access Forms 0 20th Oct 2005 06:10 AM
How can I merge to emal an MSword mail merge mail document and a . =?Utf-8?B?Q2hhcmxlcyBQcmljZQ==?= Microsoft Outlook Discussion 0 21st Mar 2005 03:53 PM
How do I mail merge when only merge document is shown in tools? =?Utf-8?B?RGF2ZUFT?= Microsoft Word Document Management 2 1st Dec 2004 03:45 PM
WORD XP mail-merge FAILS using ACCESS query =?Utf-8?B?U3VlTWFja2F5?= Microsoft Access Queries 4 29th Nov 2004 04:11 PM
Trying to get merge field count using MAX function in Mail Merge document John Wilson Microsoft Word New Users 0 24th Jul 2003 01:22 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:40 PM.