Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Phillip Phillip is offline
external usenet poster
 
Posts: 6
Default How can I find the data-source of mail merge document?

I have a folder containing over a hundred MS Word mailmerge documents.
The data for each document apears to be a different Access Database Query.
I'd like to know If I can identify the qury record source from the Word
Document?
  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default How can I find the data-source of mail merge document?

The VBA command

ActiveDocument.MailMerge.DataSource.Name

returns the name of the data source that is attached to a mail merge main
document.

It would be possible to write a macro that went through all of the documents
in a folder and inserted the name of the document and of its attached data
source into a table in a new document.

The procedure would be a modification of the code in the article "Find &
ReplaceAll on a batch of documents in the same folder" at:

http://www.word.mvps.org/FAQs/MacrosVBA/BatchFR.htm

--
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

"Phillip" wrote in message
...
I have a folder containing over a hundred MS Word mailmerge documents.
The data for each document apears to be a different Access Database Query.
I'd like to know If I can identify the qury record source from the Word
Document?



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error in Mail Merge with MS Access - can't find data source Brian Mailmerge 3 July 16th 07 02:36 PM
How can I find out what data source was used in a merge document? Penelope Mailmerge 1 April 25th 07 11:09 PM
Mail Merge can't find data source in Office XP...but it could in 2000! [email protected] Mailmerge 4 June 7th 06 03:15 PM
Word 2002 cannot find its Excel data source for mail merge harryedwards Mailmerge 5 November 23rd 05 11:09 AM
Mail Merge Error - can't find data source Aeluin Mailmerge 0 October 7th 05 12:51 AM


All times are GMT +1. The time now is 04:13 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"