VBA Word Merge -- "Invalid Merge Field"

V

Vincent

I was wondering if anyone had some ideas about this. From within our
Microsoft Access program, we perform various Microsoft Word merges.
This typically executes without any problems, but occasionally a merge
document will contain an invalid merge field and the Word program will
hang in the background causing all sort of havoc. It will hang in the
background, because the powers that be want this to appear to be a
magical process and want Word to remain invisible and unseen to the
end user. Is there any way to either suppress this error message or
make Word visible when the error occurs? Please note, I have tried
setting "DisplayAlerts=0", but this does not prevent the error from
occurring. Any help is appreciated. Thanks.

Vincent
 
V

Vincent

I was wondering if anyone had some ideas about this.  From within our
Microsoft Access program, we perform various Microsoft Word merges.
This typically executes without any problems, but occasionally a merge
document will contain an invalid merge field and the Word program will
hang in the background causing all sort of havoc.  It will hang in the
background, because the powers that be want this to appear to be a
magical process and want Word to remain invisible and unseen to the
end user.  Is there any way to either suppress this error message or
make Word visible when the error occurs?  Please note, I have tried
setting "DisplayAlerts=0", but this does not prevent the error from
occurring.  Any help is appreciated.  Thanks.

Vincent

I found a solution that works, if anyone else has this issue. For
every call to PrintOut(), make the first argument false (ie. PrintOut
(false)).

Cheers,

Vincent
 

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