Word cannot access text files temporarily

E

eugene

Hi All,

I have a Word mailmerge macro that was written in Word 2000 (or
perhaps earlier?). The macro reads text data files that are created
from an external source, opens the corresponding Word mail merge
template file (a *.doc file) and merges the template file with the
data and saves the populated merge file. Occasionally the mail merge
will have an embedded mail merge document within the main mail merge
template file - this embedded mail merge also has a data text file.

These are all done in different directories but under the same root
directory which is often accessed via a shared network drive on the
local machine that runs the macro.

This setup has worked with various client versions of Word, from 2000,
2003 and even 2007 with differing service packs over Windows XP and
Vista. My company has this setup running with approx 20 clients across
4 countries.

Recently two clients in particular have reported an issue.

It seems that their version of Word has "temporary" access issues when
trying to open text files.

In the above process this can manifest itself in three ways:
a) When opening the Word mail merge template file, the template file
will OCCASIONALLY report that it cannot access the default data source
file (text file).
b) When starting to populate the mail merge template file, the
template file will OCCASIONALLY report that it cannot access the text
data file (text file)
c) When starting to populate the embedded mail merge template file,
the embedded template file will OCCASIONALLY report that it cannot
access the embedded text data file (text file).

When encountering the above issues (b) and (c), I have programmed the
mail merge macro to Do Events, wait 30 seconds and retry. So far this
has resolved any specific reocurrence of those issues (ie the mail
merge tries again and is successful). However I cannot figure a way to
handle issue (a) as this issue occurs in the generic opening call of
any mail merge document.

When encountering the above issues I have tried manually accessing the
text file and manually performing the mail merge using the said text
files and Word CAN access the files and perform the mail merge. Our
users may use in the vicinity of 30 different templates in the day and
produce from these 30 templates almost 1,000 different mail merge
documents. So far I can observe the above issues occur say 10-20% of
the time, but the process has previous worked (and is still working
for some client sites) as an automatic process.

Short of collating the virus, firewall, operating system and version
of Word as per standard support cases, has anybody else encountered
this problem, or may know of a solution to the above problem?

I apologise in advance for such a lengthy email but hope somebody may
be able to shed some light on this issue.

TIA
Eugene
 

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